Class CalcitePreparedStatement

  • All Implemented Interfaces:
    java.lang.AutoCloseable, java.sql.ParameterMetaData, java.sql.PreparedStatement, java.sql.Statement, java.sql.Wrapper
    Direct Known Subclasses:
    CalciteJdbc41Factory.CalciteJdbc41PreparedStatement

    abstract class CalcitePreparedStatement
    extends org.apache.calcite.avatica.AvaticaPreparedStatement
    Implementation of PreparedStatement for the Calcite engine.

    This class has sub-classes which implement JDBC 3.0 and JDBC 4.0 APIs; it is instantiated using AvaticaFactory.newPreparedStatement(org.apache.calcite.avatica.AvaticaConnection, org.apache.calcite.avatica.Meta.StatementHandle, org.apache.calcite.avatica.Meta.Signature, int, int, int).

    • Field Summary

      • Fields inherited from class org.apache.calcite.avatica.AvaticaPreparedStatement

        parameterValueBatch, slots
      • Fields inherited from class org.apache.calcite.avatica.AvaticaStatement

        cancelFlag, closed, closeOnCompletion, connection, DEFAULT_FETCH_SIZE, handle, maxRowCount, openResultSet, updateCount
      • Fields inherited from interface java.sql.ParameterMetaData

        parameterModeIn, parameterModeInOut, parameterModeOut, parameterModeUnknown, parameterNoNulls, parameterNullable, parameterNullableUnknown
      • Fields inherited from interface java.sql.Statement

        CLOSE_ALL_RESULTS, CLOSE_CURRENT_RESULT, EXECUTE_FAILED, KEEP_CURRENT_RESULT, NO_GENERATED_KEYS, RETURN_GENERATED_KEYS, SUCCESS_NO_INFO
    • Constructor Summary

      Constructors 
      Modifier Constructor Description
      protected CalcitePreparedStatement​(CalciteConnectionImpl connection, org.apache.calcite.avatica.Meta.StatementHandle h, org.apache.calcite.avatica.Meta.Signature signature, int resultSetType, int resultSetConcurrency, int resultSetHoldability)
      Creates a CalcitePreparedStatement.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      CalciteConnectionImpl getConnection()  
      • Methods inherited from class org.apache.calcite.avatica.AvaticaPreparedStatement

        addBatch, clearBatch, clearParameters, copyParameterValues, execute, executeBatch, executeLargeBatch, executeLargeUpdate, executeQuery, executeUpdate, getCalendar, getMetaData, getParameter, getParameterClassName, getParameterCount, getParameterMetaData, getParameterMode, getParameterType, getParameterTypeName, getParameterValueBatch, getParameterValues, getPrecision, getScale, getSite, isNullable, isSigned, setArray, setAsciiStream, setAsciiStream, setAsciiStream, setBigDecimal, setBinaryStream, setBinaryStream, setBinaryStream, setBlob, setBlob, setBlob, setBoolean, setByte, setBytes, setCharacterStream, setCharacterStream, setCharacterStream, setClob, setClob, setClob, setDate, setDate, setDouble, setFloat, setInt, setLong, setNCharacterStream, setNCharacterStream, setNClob, setNClob, setNClob, setNString, setNull, setNull, setObject, setObject, setObject, setRef, setRowId, setShort, setSQLXML, setString, setTime, setTime, setTimestamp, setTimestamp, setUnicodeStream, setURL
      • Methods inherited from class org.apache.calcite.avatica.AvaticaStatement

        addBatch, cancel, checkOpen, clearWarnings, close, close_, closeOnCompletion, execute, execute, execute, execute, executeBatchInternal, executeInternal, executeInternal, executeLargeUpdate, executeQuery, executeQueryInternal, executeUpdate, executeUpdate, executeUpdate, executeUpdate, getBoundParameterValues, getFetchDirection, getFetchSize, getGeneratedKeys, getId, getLargeMaxRows, getLargeUpdateCount, getMaxFieldSize, getMaxRows, getMoreResults, getMoreResults, getQueryTimeout, getResultSet, getResultSetConcurrency, getResultSetHoldability, getResultSetType, getSignature, getStatementType, getUpdateCount, getWarnings, isClosed, isCloseOnCompletion, isPoolable, isWrapperFor, resetStatement, setCursorName, setEscapeProcessing, setFetchDirection, setFetchSize, setLargeMaxRows, setMaxFieldSize, setMaxRows, setPoolable, setQueryTimeout, setSignature, syncResults, unwrap
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
      • Methods inherited from interface java.sql.PreparedStatement

        setObject, setObject
      • Methods inherited from interface java.sql.Statement

        addBatch, cancel, clearWarnings, close, closeOnCompletion, enquoteIdentifier, enquoteLiteral, enquoteNCharLiteral, execute, execute, execute, execute, executeLargeUpdate, executeLargeUpdate, executeLargeUpdate, executeLargeUpdate, executeQuery, executeUpdate, executeUpdate, executeUpdate, executeUpdate, getFetchDirection, getFetchSize, getGeneratedKeys, getLargeMaxRows, getLargeUpdateCount, getMaxFieldSize, getMaxRows, getMoreResults, getMoreResults, getQueryTimeout, getResultSet, getResultSetConcurrency, getResultSetHoldability, getResultSetType, getUpdateCount, getWarnings, isClosed, isCloseOnCompletion, isPoolable, isSimpleIdentifier, setCursorName, setEscapeProcessing, setFetchDirection, setFetchSize, setLargeMaxRows, setMaxFieldSize, setMaxRows, setPoolable, setQueryTimeout
      • Methods inherited from interface java.sql.Wrapper

        isWrapperFor, unwrap
    • Constructor Detail

      • CalcitePreparedStatement

        protected CalcitePreparedStatement​(CalciteConnectionImpl connection,
                                           org.apache.calcite.avatica.Meta.StatementHandle h,
                                           org.apache.calcite.avatica.Meta.Signature signature,
                                           int resultSetType,
                                           int resultSetConcurrency,
                                           int resultSetHoldability)
                                    throws java.sql.SQLException
        Creates a CalcitePreparedStatement.
        Parameters:
        connection - Connection
        h - Statement handle
        signature - Result of preparing statement
        resultSetType - Result set type
        resultSetConcurrency - Result set concurrency
        resultSetHoldability - Result set holdability
        Throws:
        java.sql.SQLException - if database error occurs
    • Method Detail

      • getConnection

        public CalciteConnectionImpl getConnection()
                                            throws java.sql.SQLException
        Specified by:
        getConnection in interface java.sql.Statement
        Overrides:
        getConnection in class org.apache.calcite.avatica.AvaticaStatement
        Throws:
        java.sql.SQLException