opaleye-0.5.3.0: An SQL-generating DSL targeting PostgreSQL

Safe HaskellNone
LanguageHaskell2010

Opaleye.PGTypes

Contents

Description

Postgres types and functions to create Columns of those types. You may find it more convenient to use Opaleye.Constant instead.

Synopsis

Documentation

Creating SQL values

pgArray :: forall a b. IsSqlType b => (a -> Column b) -> [a] -> Column (PGArray b) #

pgRange :: forall a b. IsRangeType b => (a -> Column b) -> RangeBound a -> RangeBound a -> Column (PGRange b) #

class IsSqlType pgType where #

Minimal complete definition

showPGType

Methods

showPGType :: proxy pgType -> String #

Instances

IsSqlType PGJsonb # 

Methods

showPGType :: proxy PGJsonb -> String #

IsSqlType PGJson # 

Methods

showPGType :: proxy PGJson -> String #

IsSqlType PGBytea # 

Methods

showPGType :: proxy PGBytea -> String #

IsSqlType PGCitext # 

Methods

showPGType :: proxy PGCitext -> String #

IsSqlType PGUuid # 

Methods

showPGType :: proxy PGUuid -> String #

IsSqlType PGTimestamptz # 

Methods

showPGType :: proxy PGTimestamptz -> String #

IsSqlType PGTimestamp # 

Methods

showPGType :: proxy PGTimestamp -> String #

IsSqlType PGTime # 

Methods

showPGType :: proxy PGTime -> String #

IsSqlType PGText # 

Methods

showPGType :: proxy PGText -> String #

IsSqlType PGNumeric # 

Methods

showPGType :: proxy PGNumeric -> String #

IsSqlType PGInt2 # 

Methods

showPGType :: proxy PGInt2 -> String #

IsSqlType PGInt4 # 

Methods

showPGType :: proxy PGInt4 -> String #

IsSqlType PGInt8 # 

Methods

showPGType :: proxy PGInt8 -> String #

IsSqlType PGFloat8 # 

Methods

showPGType :: proxy PGFloat8 -> String #

IsSqlType PGFloat4 # 

Methods

showPGType :: proxy PGFloat4 -> String #

IsSqlType PGDate # 

Methods

showPGType :: proxy PGDate -> String #

IsSqlType PGBool # 

Methods

showPGType :: proxy PGBool -> String #

IsSqlType a => IsSqlType (Nullable a) # 

Methods

showPGType :: proxy (Nullable a) -> String #

IsRangeType a => IsSqlType (PGRange a) # 

Methods

showPGType :: proxy (PGRange a) -> String #

IsSqlType a => IsSqlType (PGArray a) # 

Methods

showPGType :: proxy (PGArray a) -> String #

class IsSqlType pgType => IsRangeType pgType where #

Minimal complete definition

showRangeType

Methods

showRangeType :: proxy pgType -> String #

SQL datatypes

data PGFloat4 #

Instances

data PGInt2 #

Instances

Deprecated functions

literalColumn :: Literal -> Column a #

Warning: literalColumn has been moved to Opaleye.Internal.PGTypes and will be deprecated in version 0.6

unsafePgFormatTime :: FormatTime t => Name -> String -> t -> Column c #

Warning: unsafePgFormatTime has been moved to Opaleye.Internal.PGTypes and will be deprecated in version 0.6