Safe Haskell | None |
---|---|
Language | Haskell2010 |
Class declarations for query execution
Synopsis
- class Monad query => Query query where
- type NativeResult query :: Type
- executeStatement :: Statement a -> a -> query (NativeResult query)
- executePreparedStatement :: PreparedStatement a -> a -> query (NativeResult query)
- withPreparedStatement :: Statement a -> (PreparedStatement a -> query r) -> query r
- processResult :: NativeResult query -> Result a -> query a
- class Executable statement where
- execute :: Query query => statement param -> param -> query (NativeResult query)
Documentation
class Monad query => Query query where Source #
PostgreSQL query
Since: 0.0.0
type NativeResult query :: Type Source #
Native query result
Since: 0.0.0
:: Statement a | Statement |
-> a | Statement input |
-> query (NativeResult query) |
Execute a statement.
Since: 0.0.0
executePreparedStatement Source #
:: PreparedStatement a | Prepared statement |
-> a | Statement input |
-> query (NativeResult query) |
Execute a previously prepared statement.
Since: 0.0.0
withPreparedStatement Source #
:: Statement a | Statement to prepare |
-> (PreparedStatement a -> query r) | Scope within the prepared statement may be used |
-> query r |
Prepare a statement. The prepared statement is only valid within the provided continuation.
Since: 0.0.0
:: NativeResult query | Result |
-> Result a | Result processor |
-> query a |
Process the result object.
Since: 0.0.0
Instances
(MonadIO m, MonadMask m) => Query (QueryT m) Source # | |
Defined in PostgreSQL.Query type NativeResult (QueryT m) Source # executeStatement :: Statement a -> a -> QueryT m (NativeResult (QueryT m)) Source # executePreparedStatement :: PreparedStatement a -> a -> QueryT m (NativeResult (QueryT m)) Source # withPreparedStatement :: Statement a -> (PreparedStatement a -> QueryT m r) -> QueryT m r Source # processResult :: NativeResult (QueryT m) -> Result a -> QueryT m a Source # |
class Executable statement where Source #
statement
is an executable statement.
Since: 0.0.0
:: Query query | |
=> statement param | Statement |
-> param | Statement input |
-> query (NativeResult query) |
Execute a statement.
Since: 0.0.0
Instances
Executable PreparedStatement Source # | Since: 0.0.0 |
Defined in PostgreSQL.Query.Class execute :: Query query => PreparedStatement param -> param -> query (NativeResult query) Source # | |
Executable Statement Source # | Since: 0.0.0 |
Defined in PostgreSQL.Query.Class |