Package | Description |
---|---|
com.caucho.quercus.lib.db |
Modifier and Type | Method and Description |
---|---|
protected Postgres |
PostgresResult.getConnection() |
static Postgres |
PostgresModule.pg_connect(Env env,
java.lang.String connectionString,
int connectionType)
Open a PostgreSQL connection
|
static Postgres |
PostgresModule.pg_pconnect(Env env,
java.lang.String connectionString,
int connectType)
Open a persistent PostgreSQL connection
|
Modifier and Type | Method and Description |
---|---|
static boolean |
PostgresModule.pg_cancel_query(Env env,
Postgres conn)
Cancel an asynchronous query
|
static java.lang.String |
PostgresModule.pg_client_encoding(Env env,
Postgres conn)
Gets the client encoding
|
static boolean |
PostgresModule.pg_close(Env env,
Postgres conn)
Closes a PostgreSQL connection
|
static boolean |
PostgresModule.pg_connection_busy(Env env,
Postgres conn)
Get connection is busy or not
|
static boolean |
PostgresModule.pg_connection_reset(Env env,
Postgres conn)
Reset connection (reconnect)
|
static int |
PostgresModule.pg_connection_status(Env env,
Postgres conn)
Get connection status
|
static ArrayValue |
PostgresModule.pg_convert(Env env,
Postgres conn,
java.lang.String tableName,
ArrayValue assocArray,
int options)
Convert associative array values into suitable for SQL statement
|
static boolean |
PostgresModule.pg_copy_from(Env env,
Postgres conn,
java.lang.String tableName,
ArrayValue rows,
java.lang.String delimiter,
java.lang.String nullAs)
Insert records into a table from an array
|
static ArrayValue |
PostgresModule.pg_copy_to(Env env,
Postgres conn,
java.lang.String tableName,
java.lang.String delimiter,
java.lang.String nullAs)
Copy a table to an array
|
static java.lang.String |
PostgresModule.pg_dbname(Env env,
Postgres conn)
Get the database name
|
static boolean |
PostgresModule.pg_delete(Env env,
Postgres conn,
java.lang.String tableName,
ArrayValue assocArray,
int options)
Deletes records
|
static boolean |
PostgresModule.pg_end_copy(Env env,
Postgres conn)
Sync with PostgreSQL backend
|
static StringValue |
PostgresModule.pg_errormessage(Env env,
Postgres conn)
pg_last_error() alias.
|
static StringValue |
PostgresModule.pg_escape_bytea(Env env,
Postgres conn,
StringValue data)
Escape a string for insertion into a bytea field.
|
static PostgresResult |
PostgresModule.pg_exec(Env env,
Postgres conn,
java.lang.String query)
pg_query() alias
|
static PostgresResult |
PostgresModule.pg_execute(Env env,
Postgres conn,
java.lang.String stmtName,
ArrayValue params)
Sends a request to execute a prepared statement with given parameters,
and waits for the result
|
static ArrayValue |
PostgresModule.pg_get_notify(Env env,
Postgres conn,
int resultType)
Gets SQL NOTIFY message
|
static int |
PostgresModule.pg_get_pid(Env env,
Postgres conn)
Gets the backend's process ID
|
static PostgresResult |
PostgresModule.pg_get_result(Env env,
Postgres conn)
Get asynchronous query result
|
static java.lang.String |
PostgresModule.pg_host(Env env,
Postgres conn)
Returns the host name associated with the connection
|
static boolean |
PostgresModule.pg_insert(Env env,
Postgres conn,
java.lang.String tableName,
ArrayValue assocArray,
int options)
Insert array into table
|
static StringValue |
PostgresModule.pg_last_error(Env env,
Postgres conn)
Get the last error message string of a connection
|
static java.lang.String |
PostgresModule.pg_last_notice(Env env,
Postgres conn)
Returns the last notice message from PostgreSQL server
|
static LongValue |
PostgresModule.pg_lo_create(Env env,
Postgres conn)
Create a large object
|
static boolean |
PostgresModule.pg_lo_export(Env env,
Postgres conn,
int oid,
Path path)
Export a large object to a file
|
static LongValue |
PostgresModule.pg_lo_import(Env env,
Postgres conn,
Path path)
Import a large object from file
|
static java.lang.Object |
PostgresModule.pg_lo_open(Env env,
Postgres conn,
int oid,
java.lang.String mode)
Open a large object
|
static boolean |
PostgresModule.pg_lo_unlink(Env env,
Postgres conn,
int oid)
Delete a large object
|
static LongValue |
PostgresModule.pg_locreate(Env env,
Postgres conn)
pg_lo_create() alias
|
static boolean |
PostgresModule.pg_loexport(Env env,
Postgres conn,
int oid,
Path path)
pg_lo_export() alias.
|
static LongValue |
PostgresModule.pg_loimport(Env env,
Postgres conn,
Path path)
pg_lo_import() alias.
|
static java.lang.Object |
PostgresModule.pg_loopen(Env env,
Postgres conn,
int oid,
java.lang.String mode)
pg_lo_open() alias.
|
static boolean |
PostgresModule.pg_lounlink(Env env,
Postgres conn,
int oid)
pg_lo_unlink() alias.
|
static ArrayValue |
PostgresModule.pg_meta_data(Env env,
Postgres conn,
java.lang.String tableName)
Get meta data for table
|
static java.lang.String |
PostgresModule.pg_options(Env env,
Postgres conn)
Get the options associated with the connection
|
static Value |
PostgresModule.pg_parameter_status(Env env,
Postgres conn,
StringValue paramName)
Looks up a current parameter setting of the server
|
static boolean |
PostgresModule.pg_ping(Env env,
Postgres conn)
Ping database connection
|
static StringValue |
PostgresModule.pg_port(Env env,
Postgres conn)
Return the port number associated with the connection
|
static PostgresStatement |
PostgresModule.pg_prepare(Env env,
Postgres conn,
java.lang.String stmtName,
java.lang.String query)
Submits a request to create a prepared statement with the given parameters,
and waits for completion
|
static boolean |
PostgresModule.pg_put_line(Env env,
Postgres conn,
java.lang.String data)
Send a NULL-terminated string to PostgreSQL backend
|
static PostgresResult |
PostgresModule.pg_query_params(Env env,
Postgres conn,
java.lang.String query,
ArrayValue params)
Submits a command to the server and waits for the result,
with the ability to pass parameters separately from the SQL command text
|
static PostgresResult |
PostgresModule.pg_query(Env env,
Postgres conn,
java.lang.String query)
Execute a query
|
static ArrayValue |
PostgresModule.pg_select(Env env,
Postgres conn,
java.lang.String tableName,
ArrayValue assocArray,
int options)
Select records
|
static boolean |
PostgresModule.pg_send_execute(Env env,
Postgres conn,
java.lang.String stmtName,
ArrayValue params)
Sends a request to execute a prepared statement with given parameters,
without waiting for the result(s)
|
static boolean |
PostgresModule.pg_send_prepare(Env env,
Postgres conn,
java.lang.String stmtName,
java.lang.String query)
Sends a request to create a prepared statement with the given parameters,
without waiting for completion
|
static boolean |
PostgresModule.pg_send_query_params(Env env,
Postgres conn,
java.lang.String query,
ArrayValue params)
Submits a command and separate parameters to the server
without waiting for the result(s)
|
static boolean |
PostgresModule.pg_send_query(Env env,
Postgres conn,
java.lang.String query)
Sends asynchronous query
|
static int |
PostgresModule.pg_set_client_encoding(Env env,
Postgres conn,
java.lang.String encoding)
Set the client encoding
|
static int |
PostgresModule.pg_set_error_verbosity(Env env,
Postgres conn,
int intVerbosity)
Determines the verbosity of messages returned
by pg_last_error() and pg_result_error()
|
static boolean |
PostgresModule.pg_trace(Env env,
Path path,
java.lang.String mode,
Postgres conn)
Enable tracing a PostgreSQL connection
|
static int |
PostgresModule.pg_transaction_status(Env env,
Postgres conn)
Returns the current in-transaction status of the server
|
static java.lang.String |
PostgresModule.pg_tty(Env env,
Postgres conn)
Return the TTY name associated with the connection
|
static boolean |
PostgresModule.pg_untrace(Env env,
Postgres conn)
Disable tracing of a PostgreSQL connection
|
static boolean |
PostgresModule.pg_update(Env env,
Postgres conn,
java.lang.String tableName,
ArrayValue data,
ArrayValue condition,
int options)
Update table
|
static ArrayValue |
PostgresModule.pg_version(Env env,
Postgres conn)
Returns an array with client, protocol and server version (when available)
|
Constructor and Description |
---|
PostgresResult(Postgres conn,
java.sql.ResultSetMetaData metaData)
Constructor for PostgresResult
|
PostgresResult(Postgres conn,
java.sql.Statement stmt,
java.sql.ResultSet rs)
Constructor for PostgresResult
|