mirror of
https://github.com/nikita-volkov/hasql.git
synced 2024-11-30 00:55:22 +03:00
18 lines
359 B
Haskell
18 lines
359 B
Haskell
module Main.Statements where
|
|
|
|
import qualified Hasql.Decoders as D
|
|
import qualified Hasql.Encoders as E
|
|
import Hasql.Statement
|
|
import Prelude
|
|
|
|
selectSleep :: Statement Double ()
|
|
selectSleep =
|
|
Statement sql encoder decoder True
|
|
where
|
|
sql =
|
|
"select pg_sleep($1)"
|
|
encoder =
|
|
E.param (E.nonNullable E.float8)
|
|
decoder =
|
|
D.noResult
|