dargres library

Classes

ConnectionInterface
ConnectionOwner
A owner of Connection.
ConnectionSettings
CoreConnection
ExecutionContext
PlaceholderIdentifier
placeholder Identifier
PostgreSqlPool
A QueryExecutor that manages a pool of PostgreSQL connections.
Query
QueryState
QueryType
Results
this is Result set of Rows from database
ResultStream
Row
RowDescription A single row of a query result.
RowsAffected
SslContext
TransactionContext
TransactionIsolation
See http://www.postgresql.org/docs/9.3/static/transaction-iso.html

Constants

INSIDE_CO → const int
inside inline comment eg. --
INSIDE_ES → const int
inside escaped single-quote string, E'...'
INSIDE_PN → const int
inside parameter name eg. :name
INSIDE_QI → const int
inside quoted identifier "..."
INSIDE_SQ → const int
inside single-quote string '...'
OUTSIDE → const int
outside quoted string

Functions

toStatement(String query, Map params, {String placeholderIdentifier = ':'}) List
the toStatement function is used to replace the 'placeholderIdentifier' to '$#' for postgres sql statement style Example: "INSERT INTO book (title) VALUES (:title)" to "INSERT INTO book (title) VALUES ($1)" placeholderIdentifier placeholder identifier character represents the pattern that will be replaced in the execution of the query by the supplied parameters params parameters can be a list or a map Returns String query, List<dynamic> Function(dynamic) make_vals Postgres uses $# for placeholders https://www.postgresql.org/docs/9.1/sql-prepare.html
toStatement2(String query) String
the toStatement2 function is used to replace the Question mark '?' to '$1' for sql statement "INSERT INTO book (title) VALUES (?)" to "INSERT INTO book (title) VALUES ($1)" Returns String query, List<dynamic> Function(dynamic) make_vals Postgres uses $# for placeholders https://www.postgresql.org/docs/9.1/sql-prepare.html

Exceptions / Errors

PostgresqlException
PostgreSQLException