Class AgConnection

java.lang.Object
org.postgresql.jdbc.PgConnection
net.bitnine.agensgraph.jdbc.AgConnection
All Implemented Interfaces:
AutoCloseable, Connection, Wrapper, org.postgresql.core.BaseConnection, org.postgresql.PGConnection

public class AgConnection extends org.postgresql.jdbc.PgConnection
This class defines connection to AgensGraph.
  • Nested Class Summary

    Nested classes/interfaces inherited from class org.postgresql.jdbc.PgConnection

    org.postgresql.jdbc.PgConnection.AbortCommand
  • Field Summary

    Fields inherited from class org.postgresql.jdbc.PgConnection

    defaultFetchSize, forcebinary, metadata, prepareThreshold, typemap
  • Constructor Summary

    Constructors
    Constructor
    Description
    AgConnection(org.postgresql.util.HostSpec[] hostSpecs, String user, String database, Properties info, String url)
     
  • Method Summary

    Modifier and Type
    Method
    Description
    createStatement(int resultSetType, int resultSetConcurrency, int resultSetHoldability)
     
    protected Array
    makeArray(int oid, String fieldString)
     
    Returns a prepared statement with a named parameter.
    prepareNamedParameterStatement(String queryString, int autoGeneratedKeys)
    Returns a prepared statement with a named parameter.
    prepareNamedParameterStatement(String queryString, int[] columnIndexes)
    Returns a prepared statement with a named parameter.
    prepareNamedParameterStatement(String queryString, int resultSetType, int resultSetConcurrency)
    Returns a prepared statement with a named parameter.
    prepareNamedParameterStatement(String queryString, int resultSetType, int resultSetConcurrency, int resultSetHoldability)
    Returns a prepared statement with a named parameter.
    prepareNamedParameterStatement(String queryString, String[] columnNames)
    Returns a prepared statement with a named parameter.
    prepareStatement(String sql, int resultSetType, int resultSetConcurrency, int resultSetHoldability)
     
    prepareStatement(String sql, String[] columnNames)
     

    Methods inherited from class org.postgresql.jdbc.PgConnection

    abort, abort, addDataType, addDataType, addTimerTask, addWarning, binaryTransferSend, cancelQuery, checkClosed, clearWarnings, close, commit, createArrayOf, createArrayOf, createBlob, createClob, createNClob, createQuery, createQueryObject, createSQLXML, createStatement, createStatement, createStruct, createTypeInfo, encodeString, escapeIdentifier, escapeLiteral, escapeString, execSQLQuery, execSQLQuery, execSQLUpdate, finalize, getAutoCommit, getAutosave, getBackendPID, getCatalog, getClientInfo, getClientInfo, getCopyAPI, getCursorName, getDBVersionNumber, getDefaultFetchSize, getEncoding, getFastpathAPI, getFieldMetadataCache, getForceBinary, getHideUnprivilegedObjects, getHoldability, getIsolationLevelName, getLargeObjectAPI, getLogger, getLogServerErrorDetail, getMetaData, getNetworkTimeout, getNotifications, getNotifications, getObject, getParameterStatus, getParameterStatuses, getPreferQueryMode, getPrepareThreshold, getProtocolVersion, getQueryExecutor, getReplicationAPI, getReplicationProtocol, getSchema, getServerMajorVersion, getServerMinorVersion, getStandardConformingStrings, getStringVarcharFlag, getTimestampUtils, getTransactionIsolation, getTransactionState, getTypeInfo, getTypeMap, getURL, getUserName, getWarnings, getXmlFactoryFactory, haveMinimumServerVersion, haveMinimumServerVersion, hintReadOnly, isClosed, isColumnSanitiserDisabled, isReadOnly, isValid, isWrapperFor, makeBlob, makeClob, makeSQLXML, nativeSQL, prepareCall, prepareCall, prepareCall, prepareStatement, prepareStatement, prepareStatement, prepareStatement, purgeTimerTasks, releaseSavepoint, rollback, rollback, setAutoCommit, setAutosave, setCatalog, setClientInfo, setClientInfo, setCursorName, setDefaultFetchSize, setDisableColumnSanitiser, setFlushCacheOnDeallocate, setForceBinary, setHoldability, setNetworkTimeout, setPrepareThreshold, setReadOnly, setSavepoint, setSavepoint, setSchema, setTransactionIsolation, setTypeMap, setTypeMapImpl, unwrap

    Methods inherited from class java.lang.Object

    clone, equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

  • Method Details

    • createStatement

      public Statement createStatement(int resultSetType, int resultSetConcurrency, int resultSetHoldability) throws SQLException
      Specified by:
      createStatement in interface Connection
      Overrides:
      createStatement in class org.postgresql.jdbc.PgConnection
      Throws:
      SQLException
    • prepareStatement

      public PreparedStatement prepareStatement(String sql, int resultSetType, int resultSetConcurrency, int resultSetHoldability) throws SQLException
      Specified by:
      prepareStatement in interface Connection
      Overrides:
      prepareStatement in class org.postgresql.jdbc.PgConnection
      Throws:
      SQLException
    • prepareStatement

      public PreparedStatement prepareStatement(String sql, String[] columnNames) throws SQLException
      Specified by:
      prepareStatement in interface Connection
      Overrides:
      prepareStatement in class org.postgresql.jdbc.PgConnection
      Throws:
      SQLException
    • prepareNamedParameterStatement

      public AgPreparedStatement prepareNamedParameterStatement(String queryString) throws SQLException
      Returns a prepared statement with a named parameter.
      Parameters:
      queryString - the query string
      Returns:
      a prepared statement with a named parameter
      Throws:
      SQLException - the SQL exception
    • prepareNamedParameterStatement

      public AgPreparedStatement prepareNamedParameterStatement(String queryString, int resultSetType, int resultSetConcurrency) throws SQLException
      Returns a prepared statement with a named parameter.
      Parameters:
      queryString - the query string
      resultSetType - the result set type
      resultSetConcurrency - the result set concurrency
      Returns:
      a prepared statement with a named parameter.
      Throws:
      SQLException - the SQL exception
    • prepareNamedParameterStatement

      public AgPreparedStatement prepareNamedParameterStatement(String queryString, int resultSetType, int resultSetConcurrency, int resultSetHoldability) throws SQLException
      Returns a prepared statement with a named parameter.
      Parameters:
      queryString - the query string
      resultSetType - the result set type
      resultSetConcurrency - the result set concurrency
      resultSetHoldability - the result set holdability
      Returns:
      a prepared statement with a named parameter
      Throws:
      SQLException - the SQL exception
    • prepareNamedParameterStatement

      public AgPreparedStatement prepareNamedParameterStatement(String queryString, int autoGeneratedKeys) throws SQLException
      Returns a prepared statement with a named parameter.
      Parameters:
      queryString - the query string
      autoGeneratedKeys - the auto generated keys
      Returns:
      a prepared statement with a named parameter
      Throws:
      SQLException - the SQL exception
    • prepareNamedParameterStatement

      public AgPreparedStatement prepareNamedParameterStatement(String queryString, int[] columnIndexes) throws SQLException
      Returns a prepared statement with a named parameter.
      Parameters:
      queryString - the query string
      columnIndexes - the column indexes
      Returns:
      a prepared statement with a named parameter
      Throws:
      SQLException - the SQL exception
    • prepareNamedParameterStatement

      public AgPreparedStatement prepareNamedParameterStatement(String queryString, String[] columnNames) throws SQLException
      Returns a prepared statement with a named parameter.
      Parameters:
      queryString - the query string
      columnNames - the column names
      Returns:
      a prepared statement with a named parameter
      Throws:
      SQLException - the SQL exception
    • makeArray

      protected Array makeArray(int oid, String fieldString) throws SQLException
      Overrides:
      makeArray in class org.postgresql.jdbc.PgConnection
      Throws:
      SQLException