mirror of
https://github.com/circuithub/rel8.git
synced 2024-09-19 05:17:08 +03:00
Document Query
This commit is contained in:
parent
8560de9c71
commit
eb57de9fa1
@ -23,14 +23,18 @@ import Rel8.Table.Alternative
|
||||
)
|
||||
|
||||
|
||||
-- | The @Query@ monad allows you to compose a @SELECT@ query. This monad has
|
||||
-- semantics similar to the list (@[]@) monad.
|
||||
type Query :: Type -> Type
|
||||
newtype Query a = Query (Opaleye.Select a)
|
||||
deriving newtype (Functor, Applicative, Monad)
|
||||
|
||||
|
||||
-- | '<|>:' = 'unionAll'.
|
||||
instance AltTable Query where
|
||||
(<|>:) = unionAll
|
||||
|
||||
|
||||
-- | 'emptyTable' = 'values' @[]@.
|
||||
instance AlternativeTable Query where
|
||||
emptyTable = values []
|
||||
|
Loading…
Reference in New Issue
Block a user