b~      !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`abcdefghijklmnopqrstuvwxyz{|}2015 Dylan Simon Safe-Inferred6 for discrete (non-continuous) range types, using the ~ instance$  !"# $ #"!     !"#2015 Dylan SimonNone(23468=KM$XClass indicating that the first PostgreSQL type is a range of the second. This implies * and '' instances that will work for any type.%YClass indicating that the first PostgreSQL type is an array of the second. This implies * and 'V instances that will work for any type using comma as a delimiter (i.e., anything but box2). This will only work with 1-dimensional arrays.0The character used as a delimeter. The default ,+ is correct for all standard types (except box).The cannonical representation of a PostgreSQL array of any type, which may always contain NULLs. Currenly only one-dimetional arrays are supported, although in PostgreSQL, any array may be of any dimentionality.PSupport decoding of assumed non-null columns but also still allow decoding into .Support encoding of  values into NULL.'A  PGColumn t a4 instance describes how te decode a PostgreSQL type t to a.(7Decode the PostgreSQL text representation into a value.*A PGParameter t a4 instance describes how to encode a PostgreSQL type t from a.+3Encode a value to a PostgreSQL text representation.,gEncode a value to a (quoted) literal value for use in SQL statements. Defaults to a quoted version of +-qParameters that affect how marshalling happens. Currenly we force all other relevant parameters at connect time./If integer_datetimes is on$; only relevant for binary encoding.1kA proxy type for PostgreSQL types. The type argument should be an (internal) name of a database type (see \dT+).3HA list of (nullable) data values, e.g. a single row or query parameters.43A value passed to or from PostgreSQL in raw format.59Special binary-encoded data. Not supported in all cases.6AThe standard text encoding format (also used for unknown formats)8aFinal parameter encoding function used when a (nullable) parameter is passed to a prepared query.9Final parameter encoding function used when a (nullable) parameter is passed to a prepared query accepting binary-encoded data.:sFinal parameter escaping function used when a (nullable) parameter is passed to be substituted into a simple query.;@Final column decoding function used for a nullable result value.<DFinal column decoding function used for a non-nullable result value.=OFinal column decoding function used for a nullable binary-encoded result value.>SFinal column decoding function used for a non-nullable binary-encoded result value.?TProduce a SQL string literal by wrapping (and escaping) a string with single quotes.Double-quote a value if it's "", "null", or contains any whitespace, '"', '\', or the characters given in the first argument. Checking all these things may not be worth it. We could just double-quote everything.High-precision representation of Rational as numeric. Unfortunately, numeric has an NaN, while Rational does not. NaN numeric values will produce exceptions.Representation of DiffTime as interval. PostgreSQL stores months and days separately in intervals, but DiffTime does not. We collapse all interval fields into seconds$%&'()*+,-./0123456789:;<=>?      !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\$%&'()*+,-./0123456789:;<=>?&47653?12-./*+,)'(089:;<=>%$$%&'()*+,-./0123476589:;<=>?      !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\None(+F"@+PGException is thrown upon encountering an ]N with severity of ERROR, FATAL, or PANIC. It holds the message of the error.^SPGBackendMessage represents a PostgreSQL protocol message that we'll receive. See  Phttp://www.postgresql.org/docs/current/interactive/protocol-message-formats.html._A RowDescription contains the name, type, table OID, and column number of the resulting columns(s) of a query. The column number is useful for inferring nullability.`A ParameterDescription describes the type of a given SQL query/statement parameter ($1, $2, etc.). Unfortunately, PostgreSQL does not give us nullability information for the parameter.](An ErrorResponse contains the severity, SQLSTATE#, and message of an error. See  Mhttp://www.postgresql.org/docs/current/interactive/protocol-error-fields.html.aEach DataRow (result of a query) is a list of ByteStrings (or just Nothing for null values, to distinguish them from emtpy strings). The ByteStrings can then be converted to the appropriate type by pgStringToType.bCommandComplete is bare for now, although it could be made to contain the number of rows affected by statements in a later version.cQPGFrontendMessage represents a PostgreSQL protocol message that we'll send. See  Phttp://www.postgresql.org/docs/current/interactive/protocol-message-formats.html.dRSimpleQuery takes a simple SQL string. Parameters ($1, $2, etc.) aren't allowed.e*Parse SQL Destination (prepared statement)fWDescribe a SQL query/statement. The SQL string can contain parameters ($1, $2, etc.).BAn established connection to the PostgreSQL server. These objects are not thread-safe and must only be used for a single request at a time.C>Information for how to connect to a database, to be passed to O.EThe hostname (ignored if F is g)FThe port, likely either PortNumber 5432 or  UnixSocket "tmp.s.PGSQL.5432"GThe name of the databaseJ!Log all low-level server messagesK)How to log server notice messages (e.g., print . PGError)h8Produce a human-readable string representing the messageLMessage SQLState code. See  Dhttp://www.postgresql.org/docs/current/static/errcodes-appendix.html.MBA database connection with sane defaults: localhost:5432:postgresitConvert a string to a NULL-terminated UTF-8 string. The PostgreSQL protocol transmits most strings in this format.j?Given a message, determinal the (optional) type ID and the bodyk)Send a message to PostgreSQL (low-level).lParse an incoming message.miReceive the next message from PostgreSQL (low-level). Note that this will block until it gets a message.OConnect to a PostgreSQL server.P.Disconnect cleanly from the PostgreSQL server.QPossibly re-open a connection to a different database, either reusing the connection if the given database is already connected or closing it and opening a new one. Regardless, the input connection must not be used afterwards.R Describe a SQL statement/query. A statement description consists of 0 or more parameter descriptions (a PostgreSQL type) and zero or more result field descriptions (for queries) (consist of the name of the field, the type of the field, and a nullability indicator).S;A simple query is one which requires sending only a single d message to the PostgreSQL server. The query is sent as a single string; you cannot bind parameters. Note that queries can return 0 results (an empty list).TPrepare a statement, bind it, and execute it. If the given statement has already been prepared (and not yet closed) on this connection, it will be re-used.ULike T| but requests results lazily in chunks of the given size. Does not use a named portal, so other requests may not intervene.V1Close a previously prepared query (if necessary).o@A^_nopq`rs]tuabvwxyz{c|}d~efBCDEFGHIJKhLMNijklmOPa handle from OQR SQL stringOptional type specifications1Guess nullability, otherwise assume everything is_a list of parameter types, and a list of result field names, types, and nullability indicators.S SQL string5The number of rows affected and a list of result rowsTSQL statement with placeholders7Optional type specifications (only used for first call)"Paremeters to bind to placeholders*Requested binary format for result columnsU*Chunk size (1 is common, 0 is all-at-once)V@ABCDEFGHIJKLMNOPQRSTUVCDEFGHIJKMB@ALNOPQRSTUV,@A^{zyxwvbau]sr`qpon_ttcfe~d}|B CDEFGHIJKhLMNijklmOPQRSTUV2015 Dylan SimonNone(3FM FA particular PostgreSQL type, identified by full formatted name (from  format_type or \dT).^ Generate a C& based on the environment variables: TPG_HOST (localhost); TPG_SOCK or TPG_PORT (5432); TPG_DB or user; TPG_USER or USER (postgres); TPG_PASS ()/Run an action using the Template Haskell state._?Run an action using the Template Haskell PostgreSQL connection.`Specify an alternative database to use during compilation. This lets you override the default connection parameters that are based on TPG environment variables. This should be called as a top-level declaration and produces no code. It uses Q: so is safe to call multiple times with the same database.aForce reloading of all types from the database. This may be needed if you make structural changes to the database during compile-time./Lookup a type name by OID. Error if not found.zLookup a type OID by type name. This is less common and thus less efficient than going the other way. Fail if not found.FDetermine if a type supports binary format marshalling. Checks for a 0 instance. Should be efficient.bA type-aware wrapper to RcTH expression to encode a * value to a   .dTH expression to decode a    to a () ' value.WXYZ[\]^_`abcdWXYZ[\]^_`abcd^_`aWXYZ[\]bcdWXYZ[\]^_`abcdNone23468Fe9Flags affecting how and what type of query to build with  makeQuery.g7Assume all results are nullable and don't try to guess.hcPrepare and re-use query, binding parameters of the given types (inferring the rest, like PREPARE).iA prepared query that automatically is prepared in the database the first time it is run and bound with new parameters each subsequent time.jgA simple one-shot query that simply substitutes literal representations of parameters for placeholders.lbExecute a query and return the number of rows affected (or -1 if not known) and a list of results.mfExecute a query that does not return result. Return the number of rows affected (or -1 if not known).n-Run a query and return a list of row results.oHMake a simple query directly from a query string, with no type inferencep^Make a prepared query directly from a query string and bind parameters, with no type inferenceqRun a prepared query in lazy mode, where only chunk size rows are requested at a time. If you eventually retrieve all the rows this way, it will be far less efficient than using pgQuery, since every chunk requires an additional round-trip. Although you may safely stop consuming rows early, currently you may not interleave any other database operation while reading rows. (This limitation could theoretically be lifted if required.)4Given a SQL statement with placeholders of the form ${expr}0, return a (hopefully) valid SQL statement with $N placeholders and the list of expressions. This does not understand strings or other SQL syntax, so any literal occurrence of the string ${ must be escaped as $${(. Embedded expressions may not contain { or }.4Given a SQL statement with placeholders of the form $N and a list of TH  expressions, return a new  expression that substitutes the expressions for the placeholders. This does not understand strings or other SQL syntax, so any literal occurrence of a string like $N must be escaped as $$N.re for a default (simple) query.s Construct a k from a SQL string.t!A quasi-quoter for PGSQL queries.=Used in expression context, it may contain any SQL statement [pgSQL|SELECT ...|]<. The statement may contain PostgreSQL-style placeholders ($1, $2 , ...) or in-line placeholders (${1+1}2) containing any valid Haskell expression (except {}). It will be replaced by a kJ object that can be used to perform the SQL statement. If there are more $Nr placeholders than expressions, it will instead be a function accepting the additional parameters and returning a k . Note that all occurrences of $N or ${ will be treated as placeholders, regardless of their context in the SQL (e.g., even within SQL strings or other places placeholders are disallowed by PostgreSQL), which may cause invalid SQL or other errors. If you need to pass a literal $> through in these contexts, you may double it to escape it as $$N or $${.TThe statement may start with one of more special flags affecting the interpretation: ?YTo disable nullability inference, treating all result values as nullable, thus returning + values regardless of inferred nullability.$ To create a i rather than a j', by default inferring parameter types. $(type,...)3To specify specific types to a prepared query (see  >http://www.postgresql.org/docs/current/static/sql-prepare.html for details).This can also be used at the top-level to execute SQL statements at compile-time (without any parameters and ignoring results). Here the query can only be prefixed with ! to make errors non-fatal.&efghijklmnopq-Chunk size (1 is common, 0 is all-or-nothing)rstefghijklmnopqrstkljiopefghrstmnqefghijklmnopqrst2015 Dylan SimonNone(246ubCreate a new enum type corresponding to the given PostgreSQL enum type. For example, if you have 'CREATE TYPE foo AS ENUM ('abc', 'DEF');, then !makePGEnum "foo" "Foo" ("Foo_"++) will be equivalent to: data Foo = Foo_abc | Foo_DEF deriving (Eq, Ord, Enum, Bounded) instance PGType Foo where ... registerPGType "foo" (ConT ''Foo) bRequires language extensions: TemplateHaskell, FlexibleInstances, MultiParamTypeClasses, DataKindsuPostgreSQL enum type nameHaskell type to create9How to generate constructor names from enum values, e.g.  ("Type_"++)uuuNone Convert a x<-style string with placeholders into a new style SQL string.w GqueryTuples :: String -> (PGConnection -> IO [(column1, column2, ...)])EQuery a PostgreSQL server and return the results as a list of tuples.Example (where h is a handle from }): _$(queryTuples "SELECT usesysid, usename FROM pg_user") h :: IO [(Maybe String, Maybe Integer)] x LqueryTuple :: String -> (PGConnection -> IO (Maybe (column1, column2, ...)))Convenience function to query a PostgreSQL server and return the first result as a tuple. If the query produces no results, return .Example (where h is a handle from }):@let sysid = 10::Integer;$(queryTuple "SELECT usesysid, usename FROM pg_user WHERE usesysid = {sysid}") h :: IO (Maybe (Maybe String, Maybe Integer)) @y ,execute :: String -> (PGConnection -> IO ())EConvenience function to execute a statement on the PostgreSQL server.Example (where h is a handle from }):@let rolename = "BOfH"($(execute "CREATE ROLE {rolename}") h @zRun a sequence of IO actions (presumably SQL statements) wrapped in a transaction. Unfortunately you're restricted to using this in the " Monad for now due to the use of . I'm debating adding a  MonadPeelIO version.{Roll back a transaction.|9Ignore duplicate key errors. This is also limited to the  Monad. vwxyz{|}the host to connect tothe port to connect onthe database to connect tothe username to connect asthe password to connect with5a handle to communicate with the PostgreSQL server on Pvwxyz{|} wxy|z{v}P vwxyz{|} None@ABCDEFGHIJKMOP`mnt@ACDEFGHIJKMBOP`tnm     !"#$%&'()*+,-./01234567789:;<=>?@ABCDEFGHIIJKKLMNOPQRSTUVWXYZ[\]^^_`abcdefghijkklmnopqrstuvwxyz{|}~V>?      !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`abcdefghijklmnopqrstuvwxyz{|}~Jiipostgresql-typed-0.3.0Database.PostgreSQL.Typed.RangeDatabase.PostgreSQL.Typed.Types"Database.PostgreSQL.Typed.ProtocolDatabase.PostgreSQL.Typed.THDatabase.PostgreSQL.Typed.QueryDatabase.PostgreSQL.Typed.Enum$Database.PostgreSQL.Typed.TemplatePGL ByteStringDatabase.PostgreSQL.TypedRangeEmpty UpperBoundUpper LowerBoundLowerBoundBounded Unboundedbound boundClosed makeBound lowerClosed upperClosedisEmptyfullisFullpointgetPointrangenormalbounded normalize normalize'@><@@>. intersect $fShowRange$fFunctorRange$fOrdUpperBound$fFunctorUpperBound$fOrdLowerBound$fFunctorLowerBound$fFunctorBound PGRangeType PGArrayTypeOIDPGColumnpgDecodePGBinaryParameter PGParameterpgEncode pgLiteral PGTypeEnvpgIntegerDatetimes PGBinaryType PGTypeName PGTypeProxyPGValuesPGValue PGBinaryValue PGTextValue PGNullValuepgEncodeParameterpgEncodeBinaryParameterpgEscapeParameterpgDecodeColumnpgDecodeColumnNotNullpgDecodeBinaryColumnpgDecodeBinaryColumnNotNullpgQuotePGError PGConnection PGDatabasepgDBHostpgDBPortpgDBNamepgDBUserpgDBPass pgDBDebugpgDBLogMessage pgMessageCodedefaultPGDatabase pgTypeEnv pgConnect pgDisconnect pgReconnect pgDescribe pgSimpleQuerypgPreparedQuerypgPreparedLazyQuerypgCloseStatement TPGValueInfo tpgValueNametpgValueTypeOID tpgValueTypetpgValueBinarytpgValueNullablegetTPGDatabasewithTPGConnectionuseTPGDatabasereloadTPGTypes tpgDescribetpgTypeEncodertpgTypeDecoder QueryFlags flagNullable flagPreparePGPreparedQuery PGSimpleQueryPGQuery pgRunQuery pgExecutepgQueryrawPGSimpleQueryrawPGPreparedQuery pgLazyQuery simpleFlags makePGQuerypgSQL makePGEnum PGException queryTuples queryTupleexecutewithTransactionrollback insertIgnorebaseGHC.EnumEnum pgArrayDelimPGArrayPGColumnNotNull Data.MaybeMaybePGParameterNulldQuote$fPGColumn"numeric"Ratio$fPGColumn"interval"DiffTimepgRangeElementTypepgArrayElementType PGStringType PGLiteralTypepgDecodeNotNullPGBinaryParameterNullpgEncodeBinaryNull pgEncodeNull pgLiteralNullPGBinaryColumnpgDecodeBinarypgEncodeBinary pgTypeName pgQuoteUnsafebuildBS parseDQuote encodeBytea decodeByteafixTZ showRationalbinDec$fPGBinaryColumn"uuid"UUID$fPGBinaryParameter"uuid"UUID$fPGBinaryType"uuid"$fPGBinaryColumn"boolean"Bool $fPGBinaryParameter"boolean"Bool$fPGBinaryType"boolean""$fPGBinaryColumn"interval"DiffTime%$fPGBinaryParameter"interval"DiffTime$fPGBinaryType"interval"1$fPGBinaryColumn"timestamp with time zone"UTCTime4$fPGBinaryParameter"timestamp with time zone"UTCTime($fPGBinaryType"timestamp with time zone"6$fPGBinaryColumn"timestamp without time zone"LocalTime9$fPGBinaryParameter"timestamp without time zone"LocalTime+$fPGBinaryType"timestamp without time zone"1$fPGBinaryColumn"time without time zone"TimeOfDay4$fPGBinaryParameter"time without time zone"TimeOfDay&$fPGBinaryType"time without time zone"$fPGBinaryColumn"date"Day$fPGBinaryParameter"date"Day$fPGBinaryType"date"!$fPGBinaryColumn"bytea"ByteString$$fPGBinaryParameter"bytea"ByteString"$fPGBinaryColumn"bytea"ByteString0%$fPGBinaryParameter"bytea"ByteString0$fPGBinaryType"bytea"$fPGBinaryColumnt[]$fPGBinaryParametert[]$fPGBinaryColumntByteString$fPGBinaryParametertByteString$fPGBinaryColumntByteString0$fPGBinaryParametertByteString0$fPGBinaryColumntText$fPGBinaryParametertText$fPGBinaryColumntText0$fPGBinaryParametertText0$fPGBinaryType"name"$fPGBinaryType"bpchar"!$fPGBinaryType"character varying"$fPGBinaryType"text"$fPGBinaryColumn"\"char\""Char!$fPGBinaryParameter"\"char\""Char$fPGBinaryType"\"char\""$fPGBinaryColumn"numeric"Ratio!$fPGBinaryParameter"numeric"Ratio#$fPGBinaryColumn"numeric"Scientific&$fPGBinaryParameter"numeric"Scientific$fPGBinaryType"numeric"($fPGBinaryColumn"double precision"Double+$fPGBinaryParameter"double precision"Double $fPGBinaryType"double precision"$fPGBinaryColumn"real"Float$fPGBinaryParameter"real"Float$fPGBinaryType"real"$fPGBinaryColumn"bigint"Int64 $fPGBinaryParameter"bigint"Int64$fPGBinaryType"bigint"$fPGBinaryColumn"integer"Int32!$fPGBinaryParameter"integer"Int32$fPGBinaryType"integer"$fPGBinaryColumn"smallint"Int16"$fPGBinaryParameter"smallint"Int16$fPGBinaryType"smallint"$fPGBinaryColumn"oid"Word32$fPGBinaryParameter"oid"Word32$fPGBinaryType"oid"$fPGColumn"uuid"UUID$fPGParameter"uuid"UUID $fPGRangeType"int8range""bigint"$fPGRangeType"daterange""date"2$fPGRangeType"tstzrange""timestamp with time zone"3$fPGRangeType"tsrange""timestamp without time zone" $fPGRangeType"numrange""numeric"!$fPGRangeType"int4range""integer"$fPGColumntrRange$fPGParametertrRange%$fPGArrayType"int8range[]""int8range"%$fPGArrayType"daterange[]""daterange"%$fPGArrayType"tstzrange[]""tstzrange"!$fPGArrayType"tsrange[]""tsrange"#$fPGArrayType"numrange[]""numrange"%$fPGArrayType"int4range[]""int4range"-$fPGArrayType"regdictionary[]""regdictionary"%$fPGArrayType"regconfig[]""regconfig"%$fPGArrayType"gtsvector[]""gtsvector"!$fPGArrayType"tsquery[]""tsquery"#$fPGArrayType"tsvector[]""tsvector"-$fPGArrayType"txid_snapshot[]""txid_snapshot"$fPGArrayType"uuid[]""uuid"!$fPGArrayType"cstring[]""cstring"$fPGArrayType"record[]""record"!$fPGArrayType"regtype[]""regtype"#$fPGArrayType"regclass[]""regclass")$fPGArrayType"regoperator[]""regoperator"!$fPGArrayType"regoper[]""regoper"+$fPGArrayType"regprocedure[]""regprocedure"%$fPGArrayType"refcursor[]""refcursor"!$fPGArrayType"numeric[]""numeric"$fPGArrayType"varbit[]""varbit"$fPGArrayType"bit[]""bit"9$fPGArrayType"time with time zone[]""time with time zone"#$fPGArrayType"interval[]""interval"C$fPGArrayType"timestamp with time zone[]""timestamp with time zone"I$fPGArrayType"timestamp without time zone[]""timestamp without time zone"?$fPGArrayType"time without time zone[]""time without time zone"$fPGArrayType"date[]""date"5$fPGArrayType"character varying[]""character varying"$fPGArrayType"bpchar[]""bpchar"!$fPGArrayType"aclitem[]""aclitem"$fPGArrayType"inet[]""inet"!$fPGArrayType"macaddr[]""macaddr"$fPGArrayType"money[]""money"$fPGArrayType"circle[]""circle"%$fPGArrayType"tinterval[]""tinterval"!$fPGArrayType"reltime[]""reltime"!$fPGArrayType"abstime[]""abstime"3$fPGArrayType"double precision[]""double precision"$fPGArrayType"real[]""real"$fPGArrayType"cidr[]""cidr"$fPGArrayType"line[]""line"!$fPGArrayType"polygon[]""polygon"$fPGArrayType"box[]""box"$fPGArrayType"path[]""path"$fPGArrayType"lseg[]""lseg"$fPGArrayType"point[]""point"$fPGArrayType"xml[]""xml"$fPGArrayType"json[]""json"%$fPGArrayType"oidvector[]""oidvector"$fPGArrayType"cid[]""cid"$fPGArrayType"xid[]""xid"$fPGArrayType"tid[]""tid"$fPGArrayType"oid[]""oid"$fPGArrayType"text[]""text"!$fPGArrayType"regproc[]""regproc"!$fPGArrayType"integer[]""integer"'$fPGArrayType"int2vector[]""int2vector"#$fPGArrayType"smallint[]""smallint"$fPGArrayType"bigint[]""bigint"$fPGArrayType"name[]""name"#$fPGArrayType"\"char\"[]""\"char\""$fPGArrayType"bytea[]""bytea"!$fPGArrayType"boolean[]""boolean"$fPGColumnta[]$fPGParameterta[]"$fPGLiteralType"numeric"Scientific$fPGParameter"numeric"Ratio$fPGParameter"interval"DiffTime+$fPGColumn"timestamp with time zone"UTCTime.$fPGParameter"timestamp with time zone"UTCTime0$fPGColumn"timestamp without time zone"LocalTime3$fPGParameter"timestamp without time zone"LocalTime+$fPGColumn"time without time zone"TimeOfDay.$fPGParameter"time without time zone"TimeOfDay$fPGColumn"date"Day$fPGParameter"date"Day$fPGColumn"bytea"ByteString$fPGParameter"bytea"ByteString$fPGColumn"bytea"ByteString0$fPGParameter"bytea"ByteString0$fPGStringType"bpchar"$fPGStringType"name"!$fPGStringType"character varying"$fPGStringType"text"$fPGColumntText$fPGParametertText$fPGColumntText0$fPGParametertText0$fPGColumntByteString$fPGParametertByteString$fPGColumntByteString0$fPGParametertByteString0 $fPGColumnt[]$fPGParametert[]$fPGColumn"\"char\""Char$fPGParameter"\"char\""Char'$fPGLiteralType"double precision"Double$fPGLiteralType"real"Float$fPGLiteralType"bigint"Int64$fPGLiteralType"integer"Int32$fPGLiteralType"smallint"Int16$fPGLiteralType"oid"Word32$fPGColumn"boolean"Bool$fPGParameter"boolean"Bool $fPGColumnta$fPGParameterta$fPGColumnNotNulltMaybe$fPGColumnNotNullta$fPGBinaryParameterNulltMaybe$fPGBinaryParameterNullta$fPGParameterNulltMaybe$fPGParameterNullta ErrorResponsePGBackendMessageRowDescriptionParameterDescriptionDataRowCommandCompletePGFrontendMessage SimpleQueryParseDescribenetwork-2.6.0.2Network UnixSocketdisplayMessagepgString messageBodypgSendgetMessageBody pgReceive ReadyForQueryPortalSuspended ParseCompleteParameterStatusNoticeResponseNoData messageFieldsEmptyQueryResponse CloseComplete BindCompleteBackendKeyDataAuthenticationMD5PasswordAuthenticationCleartextPasswordAuthenticationOk TerminateSyncPasswordMessage queryString parseTypesFlushExecuteCloseBind statementNamebindParameters binaryColumns CancelRequestStartupMessage MessageFieldsColDescriptioncolNamecolTable colNumbercolType colModifier colBinary connHandle connDatabaseconnPidconnKeyconnParameters connTypeEnvconnPreparedStatements connState connInputPGState StateClosedStateTransactionFailedStateTransaction StateIdle StateUnknown makeMessagedefaultLogMessage connDebugconnLogMessagemd5nulpgFlush getPGStringgetByteStringNulgetMessageFields getMessagepgRecvpgSync rowsAffected fixBinarypgPreparedBind$fExceptionPGError $fShowPGError$fEqPGDatabaseTPGType withTPGStatetpgType getTPGTypeOIDtpgTypeIsBinaryTPGState tpgConnectiontpgTypestpgState tpgLoadTypestpgInit typeApplysqlPlaceholders sqlSubstituteGHC.BaseString QueryParser PreparedQuery PGRawQuery rawParserstringL+$+ splitCommastrimqqQueryqqTop$fFunctorQueryParser$fPGQueryQueryParsera$fPGRawQueryPreparedQuery$fPGQueryPreparedQuery[]$fPGRawQuerySimpleQuery$fPGQuerySimpleQuery[]querySQLNothingghc-prim GHC.TypesIOControl.Exception.Base onException