The postgresql-typed package

[Tags:bsd3, library, test]

Automatically type-check SQL statements at compile time. Uses Template Haskell and the raw PostgreSQL protocol to describe SQL statements at compile time and provide appropriate type marshalling for both parameters and results. Allows not only syntax verification of your SQL but also full type safety between your SQL and Haskell. Supports many built-in PostgreSQL types already, including arrays and ranges, and can be easily extended in user code to support any other types.

Also includes an optional HDBC backend that, since it uses the raw PostgreSQL protocol, may be more efficient than the normal libpq backend in some cases (though provides no more type safety than HDBC-postgresql when used without templates).

Originally based on Chris Forno's templatepg library.

Properties

Versions 0.3.0, 0.3.1, 0.3.2, 0.3.3, 0.4.0, 0.4.1, 0.4.2, 0.4.2.1, 0.4.2.2, 0.4.3, 0.4.4, 0.4.5, 0.5.0, 0.5.1
Dependencies aeson (>=0.7), array, attoparsec (>=0.12 && <0.14), base (>=4.8 && <5), binary, bytestring (>=0.10.2), containers, cryptonite (>=0.5), haskell-src-meta, HDBC (>=2.2), memory (>=0.5), network, old-locale, postgresql-binary (>=0.8), scientific (>=0.3), template-haskell, text (>=1), time, utf8-string, uuid (>=1.3) [details]
License BSD3
Copyright 2010-2013 Chris Forno, 2014-2017 Dylan Simon
Author Dylan Simon
Maintainer Dylan Simon <dylan-pgtyped@dylex.net>
Category Database
Home page https://github.com/dylex/postgresql-typed
Bug tracker https://github.com/dylex/postgresql-typed/issues
Source repository head: git clone git://github.com/dylex/postgresql-typed
Uploaded Wed Mar 22 20:36:08 UTC 2017 by DylanSimon
Distributions LTSHaskell:0.5.1, NixOS:0.5.1, Stackage:0.5.1, Tumbleweed:0.5.1
Downloads 1248 total (39 in the last 30 days)
Votes
0 []
Status Docs available [build log]
Last success reported on 2017-03-22 [all 1 reports]
Hackage Matrix CI

Modules

[Index]

Flags

NameDescriptionDefaultType
md5Enable md5 password authentication method.EnabledAutomatic
binaryUse binary protocol encoding via postgresql-binary. This may put additional restrictions on supported PostgreSQL server versions.EnabledAutomatic
textSupport Text string values via text (implied by binary).EnabledAutomatic
uuidSupport the UUID type via uuid (implied by binary).EnabledAutomatic
scientificSupport decoding numeric via scientific (implied by binary).EnabledAutomatic
aesonSupport decoding json via aeson.EnabledAutomatic
hdbcProvide an HDBC driver backend using the raw PostgreSQL protocol.EnabledAutomatic

Use -f <flag> to enable a flag, or -f -<flag> to disable that flag. More info

Downloads

Maintainer's Corner

For package maintainers and hackage trustees