runReturningMany :: (MonadBeam be m, FromBackendRow be x) => BeamSqlBackendSyntax be -> (m (Maybe x) -> m a) -> m a
Run a query determined by the given syntax, providing an action that
will be called to consume the results from the database (if any). The
action will get a reader action that can be used to fetch the next
row. When this reader action returns Nothing, there are no rows
left to consume. When the reader action returns, the database result
is freed.
ComparatorQuantifierAny :: ComparatorQuantifier
No documentation available.
quantifyOverAny :: IsSql92QuantifierSyntax quantifier => quantifier
No documentation available.
type ManyToMany be (db :: Type -> Type -> Type) (left :: Type -> Type -> Type) (right :: Type -> Type -> Type) = forall s . (BeamSqlBackend be, SqlEq QExpr be s PrimaryKey left QExpr be s, SqlEq QExpr be s PrimaryKey right QExpr be s) => Q be db s left QExpr be s -> Q be db s right QExpr be s -> Q be db s (left QExpr be s, right QExpr be s)
Convenience type to declare many-to-many relationships. See the manual
section on relationships for more information
type ManyToManyThrough be (db :: Type -> Type -> Type) (through :: Type -> Type -> Type) (left :: Type -> Type -> Type) (right :: Type -> Type -> Type) = forall s . (BeamSqlBackend be, SqlEq QExpr be s PrimaryKey left QExpr be s, SqlEq QExpr be s PrimaryKey right QExpr be s) => Q be db s left QExpr be s -> Q be db s right QExpr be s -> Q be db s (through QExpr be s, left QExpr be s, right QExpr be s)
Convenience type to declare many-to-many relationships with additional
data. See the manual section on relationships for more
information
type OneToMany be (db :: Type -> Type -> Type) s (one :: Type -> Type -> Type) (many :: Type -> Type -> Type) = (BeamSqlBackend be, BeamSqlBackendCanSerialize be Bool) => one QExpr be s -> Q be db s many QExpr be s
Convenience type to declare one-to-many relationships. See the manual
section on relationships for more information
type OneToManyOptional be (db :: Type -> Type -> Type) s (tbl :: Type -> Type -> Type) (rel :: Type -> Type -> Type) = (BeamSqlBackend be, BeamSqlBackendCanSerialize be Bool, BeamSqlBackendCanSerialize be SqlNull) => tbl QExpr be s -> Q be db s rel Nullable QExpr be s
Convenience type to declare one-to-many relationships with a nullable
foreign key. See the manual section on relationships for more
information
manyToManyPassthrough_ :: forall be (db :: (Type -> Type) -> Type) joinThrough left right s . (Database be db, Table joinThrough, Table left, Table right, BeamSqlBackend be, SqlEq (QExpr be s) (PrimaryKey left (QExpr be s)), SqlEq (QExpr be s) (PrimaryKey right (QExpr be s))) => DatabaseEntity be db (TableEntity joinThrough) -> (joinThrough (QExpr be s) -> PrimaryKey left (QExpr be s)) -> (joinThrough (QExpr be s) -> PrimaryKey right (QExpr be s)) -> Q be db s (left (QExpr be s)) -> Q be db s (right (QExpr be s)) -> Q be db s (joinThrough (QExpr be s), left (QExpr be s), right (QExpr be s))
Used to define many-to-many relationships with additional data. Takes
the join table and two key extraction functions from that table to the
related tables. Also takes two Qs representing the table
sources to relate.
See the manual for more information.
manyToMany_ :: forall be (db :: (Type -> Type) -> Type) joinThrough left right s . (Database be db, Table joinThrough, Table left, Table right, BeamSqlBackend be, SqlEq (QExpr be s) (PrimaryKey left (QExpr be s)), SqlEq (QExpr be s) (PrimaryKey right (QExpr be s))) => DatabaseEntity be db (TableEntity joinThrough) -> (joinThrough (QExpr be s) -> PrimaryKey left (QExpr be s)) -> (joinThrough (QExpr be s) -> PrimaryKey right (QExpr be s)) -> Q be db s (left (QExpr be s)) -> Q be db s (right (QExpr be s)) -> Q be db s (left (QExpr be s), right (QExpr be s))
Used to define many-to-many relationships without any additional data.
Takes the join table and two key extraction functions from that table
to the related tables. Also takes two Qs representing the table
sources to relate.
See the manual for more information.
oneToManyOptional_ :: forall be (db :: (Type -> Type) -> Type) tbl rel s . (BeamSqlBackend be, Database be db, Table tbl, Table rel, HasTableEqualityNullable be (PrimaryKey tbl)) => DatabaseEntity be db (TableEntity rel) -> (rel (QExpr be s) -> PrimaryKey tbl (Nullable (QExpr be s))) -> tbl (QExpr be s) -> Q be db s (rel (Nullable (QExpr be s)))
Used to define one-to-many (or one-to-one) relationships with a
nullable foreign key. Takes the table to fetch, a way to extract the
foreign key from that table, and the table to relate to.