persistent-sqlite-1.2.0: Backend for the persistent library using sqlite3.

Safe Haskell | None

Database.Sqlite

Description

A port of the direct-sqlite package for dealing directly with `PersistValue`s.

# Documentation

data Connection

data Statement

data Error

Constructors

ErrorOK |
ErrorError |
ErrorInternal |
ErrorPermission |
ErrorAbort |
ErrorBusy |
ErrorLocked |
ErrorNoMemory |
ErrorReadOnly |
ErrorInterrupt |
ErrorIO |
ErrorNotFound |
ErrorCorrupt |
ErrorFull |
ErrorCan'tOpen |
ErrorProtocol |
ErrorEmpty |
ErrorSchema |
ErrorTooBig |
ErrorConstraint |
ErrorMismatch |
ErrorMisuse |
ErrorNoLargeFileSupport |
ErrorAuthorization |
ErrorFormat |
ErrorRange |
ErrorNotAConnection |
ErrorRow |
ErrorDone |

Instances

Eq Error |
Show Error |

data StepResult

Constructors

Row |
Done |

Instances

Eq StepResult |
Show StepResult |

open :: Text -> IO Connection

close :: Connection -> IO ()

prepare :: Connection -> Text -> IO Statement

step :: Statement -> IO StepResult

reset :: Connection -> Statement -> IO ()

finalize :: Statement -> IO ()

bindBlob :: Statement -> Int -> ByteString -> IO ()

bindDouble :: Statement -> Int -> Double -> IO ()

bindInt :: Statement -> Int -> Int -> IO ()

bindInt64 :: Statement -> Int -> Int64 -> IO ()

bindNull :: Statement -> Int -> IO ()

bindText :: Statement -> Int -> Text -> IO ()

bind :: Statement -> [PersistValue] -> IO ()

column :: Statement -> Int -> IO PersistValue

columns :: Statement -> IO [PersistValue]

changes :: Connection -> IO Int64