persistent-1.1.5.1: Type-safe, multi-backend data serialization.

Safe Haskell | None

Database.Persist.GenericSql.Raw

# Documentation

withStmt :: (MonadSqlPersist m, MonadResource m) => Text -> [PersistValue] -> Source m [PersistValue]

execute :: MonadSqlPersist m => Text -> [PersistValue] -> m ()

executeCount :: MonadSqlPersist m => Text -> [PersistValue] -> m Int64

newtype SqlPersist m a

Constructors

SqlPersist |

Fields

unSqlPersist :: ReaderT Connection m a

Instances

MonadTrans SqlPersist |
MonadTransControl SqlPersist |
MonadBaseControl backend m => MonadBaseControl backend (SqlPersist m) |
MonadBase backend m => MonadBase backend (SqlPersist m) |
Monad m => Monad (SqlPersist m) |
Functor m => Functor (SqlPersist m) |
MonadPlus m => MonadPlus (SqlPersist m) |
Applicative m => Applicative (SqlPersist m) |
MonadThrow m => MonadThrow (SqlPersist m) |
MonadResource m => MonadResource (SqlPersist m) |
MonadLogger m => MonadLogger (SqlPersist m) |
MonadIO m => MonadIO (SqlPersist m) |
(MonadResource m, MonadLogger m) => PersistUnique (SqlPersist m) |
(MonadResource m, MonadLogger m) => PersistStore (SqlPersist m) |
(MonadIO m, MonadLogger m) => MonadSqlPersist (SqlPersist m) |
(MonadResource m, MonadLogger m) => PersistQuery (SqlPersist m) |

getStmt' :: Connection -> Text -> IO Statement

getStmt :: MonadSqlPersist m => Text -> m Statement

data SqlBackend

Instances

PathPiece (KeyBackend SqlBackend entity) |

class (MonadIO m, MonadLogger m) => MonadSqlPersist m where

Methods

askSqlConn :: m Connection

Instances

MonadSqlPersist m => MonadSqlPersist (ResourceT m) |
MonadSqlPersist m => MonadSqlPersist (LoggingT m) |
MonadSqlPersist m => MonadSqlPersist (ListT m) |
MonadSqlPersist m => MonadSqlPersist (MaybeT m) |
MonadSqlPersist m => MonadSqlPersist (IdentityT m) |
(MonadIO m, MonadLogger m) => MonadSqlPersist (SqlPersist m) |
MonadSqlPersist m => MonadSqlPersist (ContT r m) |
(Error e, MonadSqlPersist m) => MonadSqlPersist (ErrorT e m) |
MonadSqlPersist m => MonadSqlPersist (ReaderT r m) |
MonadSqlPersist m => MonadSqlPersist (StateT s m) |
MonadSqlPersist m => MonadSqlPersist (StateT s m) |
(Monoid w, MonadSqlPersist m) => MonadSqlPersist (WriterT w m) |
(Monoid w, MonadSqlPersist m) => MonadSqlPersist (WriterT w m) |
MonadSqlPersist m => MonadSqlPersist (ConduitM i o m) |
(Monoid w, MonadSqlPersist m) => MonadSqlPersist (RWST r w s m) |
(Monoid w, MonadSqlPersist m) => MonadSqlPersist (RWST r w s m) |
MonadSqlPersist m => MonadSqlPersist (Pipe l i o u m) |

data StatementAlreadyFinalized

Constructors

StatementAlreadyFinalized Text |

Instances

Show StatementAlreadyFinalized |
Typeable StatementAlreadyFinalized |
Exception StatementAlreadyFinalized |