com.informix.jdbc

Interface IfmxStatement

  • All Superinterfaces:
    java.lang.AutoCloseable, java.sql.Statement, java.sql.Wrapper


    public interface IfmxStatement
    extends java.sql.Statement

    The interface contains extensions to the standard JDBC Statement interface.

    See Also:
    Connection.createStatement(), Statement, ResultSet
    • Field Summary

      • 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
    • Method Summary

      All Methods Instance Methods Abstract Methods 
      Modifier and Type Method and Description
      java.sql.ResultSet executeQuery(java.lang.String sql, boolean withHold)
      An extension to execute an SQL statement that returns a single ResultSet.
      boolean getAutoFree()
      An extension that returns the current autofree mode of this statement.
      long getBigSerial()
      An extension that returns the bigserial value of the last row inserted.
      int getFetchBufferSize()
      returns the fetch buffer size if set for this statement object
      int getSerial()
      An extension that returns the serial value of the last row inserted.
      long getSerial8()
      An extension that returns the serial8 value of the last row inserted.
      void setAutoFree(boolean flag)
      An extension that allows the user to set the autofree property for this statement.
      void setFetchBufferSize(int bufferSize)
      An extension that sets the buffer size for this Statement object for fetch operation This value will override any FET_BUF_SIZE connection level property and is useful when OPTOFC property is set Server will use this value as hint to determin the maximum buffer size to send the data to the clients.
      java.util.stream.Stream<com.informix.jdbc.IfxBSONObject> stream(java.lang.String sql)
      Executes the provided SQL statement and returns a java Stream of the results as BSON Objects Uses the USE_SPLITERATOR streaming option
      java.util.stream.Stream<com.informix.jdbc.IfxBSONObject> stream(java.lang.String sql, com.informix.jdbc.STREAMS_FETCHING fetchOption)
      Executes the provided SQL statement and returns a java Stream of the results as BSON Objects
      • Methods inherited from interface java.sql.Statement

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

        isWrapperFor, unwrap
    • Method Detail

      • getSerial

        int getSerial()
               throws java.sql.SQLException
        An extension that returns the serial value of the last row inserted.
        Returns:
        The serial value of the last row inserted. If no rows were inserted, returns 0.
        Throws:
        java.sql.SQLException - if there is a database access error
      • getSerial8

        long getSerial8()
                 throws java.sql.SQLException
        An extension that returns the serial8 value of the last row inserted.
        Returns:
        The serial8 value of the last row inserted. If no rows were inserted, returns 0.
        Throws:
        java.sql.SQLException - if there is a database access error
      • setAutoFree

        void setAutoFree(boolean flag)
        An extension that allows the user to set the autofree property for this statement. The resource for this statement is immediately released after the statement is executed. If the statement is a query, the resource is released after the last row is fetched.
        Parameters:
        flag - Indicates whether the autofree property is true (set) or false.
      • getAutoFree

        boolean getAutoFree()
        An extension that returns the current autofree mode of this statement.
        Returns:
        the autofree value of this statement: true (set) or false.
      • executeQuery

        java.sql.ResultSet executeQuery(java.lang.String sql,
                                        boolean withHold)
                                 throws java.sql.SQLException
        An extension to execute an SQL statement that returns a single ResultSet. The statement is executed with a hold cursor that spans across the transaction boundary.
        Parameters:
        sql - The SQL statement.
        withHold - Specifies whether the cursor has a hold or not.
        Returns:
        the table of data produced by the SQL statement.
        Throws:
        java.sql.SQLException - if there is a database access error
      • getBigSerial

        long getBigSerial()
                   throws java.sql.SQLException
        An extension that returns the bigserial value of the last row inserted.
        Returns:
        The bigserial value of the last row inserted. If no rows were inserted, returns 0.
        Throws:
        java.sql.SQLException - if there is a database access error
      • setFetchBufferSize

        void setFetchBufferSize(int bufferSize)
        An extension that sets the buffer size for this Statement object for fetch operation This value will override any FET_BUF_SIZE connection level property and is useful when OPTOFC property is set Server will use this value as hint to determin the maximum buffer size to send the data to the clients.
        Parameters:
        bufferSize - number of bytes not exceeding 2GB
      • getFetchBufferSize

        int getFetchBufferSize()
        returns the fetch buffer size if set for this statement object
        Returns:
        int Fetch buffer size
      • stream

        java.util.stream.Stream<com.informix.jdbc.IfxBSONObject> stream(java.lang.String sql)
                                                                 throws java.sql.SQLException
        Executes the provided SQL statement and returns a java Stream of the results as BSON Objects Uses the USE_SPLITERATOR streaming option
        Parameters:
        sql - SQL Statement to execute
        Returns:
        a stream of BSON objects, one for each row
        Throws:
        java.sql.SQLException - if there is a database access error
      • stream

        java.util.stream.Stream<com.informix.jdbc.IfxBSONObject> stream(java.lang.String sql,
                                                                        com.informix.jdbc.STREAMS_FETCHING fetchOption)
                                                                 throws java.sql.SQLException
        Executes the provided SQL statement and returns a java Stream of the results as BSON Objects
        Parameters:
        sql - SQL Statement to execute
        fetchOption - fetchOption Whether you fetch the data upfront (PREFETCH) or use a SPLITERATOR
        Returns:
        a stream of BSON objects, one for each row
        Throws:
        java.sql.SQLException - if there is a database access error