Module
SqlSquared
- Package
- purescript-sql-squared
- Repository
- slamdata/purescript-sql-squared
#SqlModule Source
type SqlModule = SqlModuleF Sql
#printQuery Source
printQuery :: SqlQuery -> String
#printModule Source
printModule :: SqlModule -> String
#encodeJson Source
encodeJson :: Sql -> Json
#encodeJsonQuery Source
encodeJsonQuery :: SqlQuery -> Json
#encodeJsonModule Source
encodeJsonModule :: SqlModule -> Json
Re-exports from SqlSquared.Constructors
#unop Source
unop :: forall f t. Corecursive t (SqlF f) => UnaryOperator -> t -> t
#projection Source
projection :: forall t. t -> Projection t
#pars Source
pars :: forall f t. Corecursive t (SqlF f) => t -> t
#invokeFunction Source
invokeFunction :: forall f t. Corecursive t (SqlF f) => String -> List t -> t
#buildSelect Source
buildSelect :: forall f t. Corecursive t (SqlF f) => (SelectR t -> SelectR t) -> t
#binop Source
binop :: forall f t. Corecursive t (SqlF f) => BinaryOperator -> t -> t -> t
#as Source
as :: forall t. String -> Projection t -> Projection t
Re-exports from SqlSquared.Lenses
#_tablePath Source
_tablePath :: forall r a. Lens' { tablePath :: a | r } a
#_relations Source
_relations :: forall r a. Lens' { relations :: a | r } a
#_projections Source
_projections :: forall r a. Lens' { projections :: a | r } a
#_isDistinct Source
_isDistinct :: forall r a. Lens' { isDistinct :: a | r } a
#_aliasName Source
_aliasName :: forall r a. Lens' { aliasName :: a | r } a
#_StringLiteral Source
_StringLiteral :: forall t. Recursive t (SqlF EJsonF) => Corecursive t (SqlF EJsonF) => Prism' t String
#_SetLiteral Source
_SetLiteral :: forall f t. Recursive t (SqlF f) => Corecursive t (SqlF f) => Prism' t (List t)
#_Projection Source
_Projection :: forall a. Iso' (Projection a) { alias :: Maybe String, expr :: a }
#_NullLiteral Source
_NullLiteral :: forall t. Recursive t (SqlF EJsonF) => Corecursive t (SqlF EJsonF) => Prism' t Unit
#_MapLiteral Source
_MapLiteral :: forall t. Recursive t (SqlF EJsonF) => Corecursive t (SqlF EJsonF) => Prism' t (Array (t × t))
#_InvokeFunction Source
_InvokeFunction :: forall f t. Recursive t (SqlF f) => Corecursive t (SqlF f) => Prism' t (InvokeFunctionR t)
#_IntLiteral Source
_IntLiteral :: forall t. Recursive t (SqlF EJsonF) => Corecursive t (SqlF EJsonF) => Prism' t HugeInt
#_DecimalLiteral Source
_DecimalLiteral :: forall t. Recursive t (SqlF EJsonF) => Corecursive t (SqlF EJsonF) => Prism' t HugeNum
#_BoolLiteral Source
_BoolLiteral :: forall t. Recursive t (SqlF EJsonF) => Corecursive t (SqlF EJsonF) => Prism' t Boolean
#_ArrayLiteral Source
_ArrayLiteral :: forall t. Recursive t (SqlF EJsonF) => Corecursive t (SqlF EJsonF) => Prism' t (Array t)
Re-exports from SqlSquared.Parser
#TokenStream Source
type TokenStream = Array PositionedToken
#PositionedToken Source
type PositionedToken = { position :: Position, token :: Token }
#printToken Source
printToken :: Token -> String
#prettyParse Source
prettyParse :: forall a. (String -> Either ParseError a) -> String -> Either String a
#parseQuery Source
parseQuery :: forall t. Corecursive t (SqlF EJsonF) => String -> Either ParseError (SqlQueryF t)
#parseModule Source
parseModule :: forall t. Corecursive t (SqlF EJsonF) => String -> Either ParseError (SqlModuleF t)
#parse Source
parse :: forall t. Corecursive t (SqlF EJsonF) => String -> Either ParseError t
Re-exports from SqlSquared.Signature
#UnopR Source
type UnopR a = { expr :: a, op :: UnaryOperator }
#UnaryOperator Source
#TableRelR Source
type TableRelR = { alias :: Maybe String, path :: Either (AbsFile Unsandboxed) (RelFile Unsandboxed) }
#SqlModuleF Source
newtype SqlModuleF a
Constructors
Instances
(Eq a) => Eq (SqlModuleF a)
(Ord a) => Ord (SqlModuleF a)
Newtype (SqlModuleF a) _
Eq1 SqlModuleF
Ord1 SqlModuleF
Functor SqlModuleF
Foldable SqlModuleF
Traversable SqlModuleF
#SqlF Source
#Projection Source
newtype Projection a
Constructors
Projection { alias :: Maybe String, expr :: a }
Instances
Functor Projection
Newtype (Projection a) _
(Eq a) => Eq (Projection a)
(Ord a) => Ord (Projection a)
Foldable Projection
Traversable Projection
#InvokeFunctionR Source
type InvokeFunctionR a = { args :: List a, name :: String }
#BinopR Source
type BinopR a = { lhs :: a, op :: BinaryOperator, rhs :: a }
#BinaryOperator Source
#unopToString Source
unopToString :: UnaryOperator -> String
#printUnaryOperator Source
printUnaryOperator :: String -> UnaryOperator -> String
#printOrderType Source
printOrderType :: OrderType -> String
#printJoinType Source
printJoinType :: JoinType -> String
#printIdent Source
printIdent :: String -> String
#printBinaryOperator Source
printBinaryOperator :: String -> String -> BinaryOperator -> String
#decodeJsonSqlF Source
decodeJsonSqlF :: forall l. CoalgebraM (Either String) l Json -> CoalgebraM (Either String) (SqlF l) Json
#arbitrarySqlF Source
arbitrarySqlF :: forall l. CoalgebraM Gen l Int -> CoalgebraM Gen (SqlF l) Int
- Modules
- SqlSquared
- SqlSquared.
Constructors - SqlSquared.
Lenses - SqlSquared.
Parser - SqlSquared.
Parser. Tokenizer - SqlSquared.
Signature - SqlSquared.
Signature. BinaryOperator - SqlSquared.
Signature. Case - SqlSquared.
Signature. GroupBy - SqlSquared.
Signature. Ident - SqlSquared.
Signature. JoinType - SqlSquared.
Signature. OrderBy - SqlSquared.
Signature. OrderType - SqlSquared.
Signature. Projection - SqlSquared.
Signature. Relation - SqlSquared.
Signature. UnaryOperator - SqlSquared.
Utils