Safe Haskell | Safe-Inferred |
---|---|
Language | Haskell2010 |
This module defines translation functions for queries which select data.
Principally this includes translating the query
root field, but parts are
also reused for serving the responses for mutations.
Synopsis
- fromQueryRootField :: QueryDB 'MSSQL Void Expression -> FromIr Select
- fromSelect :: JsonAggSelect -> AnnSelectG 'MSSQL (AnnFieldG 'MSSQL Void) Expression -> FromIr Select
- fromSourceRelationship :: NonEmpty Object -> HashMap FieldName (ColumnName, ScalarType) -> FieldName -> (FieldName, SourceRelationshipSelection 'MSSQL Void (Const Expression)) -> FromIr Select
Documentation
fromQueryRootField :: QueryDB 'MSSQL Void Expression -> FromIr Select Source #
This is the top-level entry point for translation of Query root fields.
fromSelect :: JsonAggSelect -> AnnSelectG 'MSSQL (AnnFieldG 'MSSQL Void) Expression -> FromIr Select Source #
fromSourceRelationship Source #
:: NonEmpty Object | List of json objects, each of which becomes a row of the table |
-> HashMap FieldName (ColumnName, ScalarType) | The above objects have this schema |
-> FieldName | |
-> (FieldName, SourceRelationshipSelection 'MSSQL Void (Const Expression)) | |
-> FromIr Select |
Used in planSourceRelationship
, which is in
turn used by to implement mkDBRemoteRelationship
for BackendExecute
.
For more information, see the module/documentation of Source
.