Package com.clickhouse.jdbc.internal
Class StreamBasedPreparedStatement
java.lang.Object
com.clickhouse.jdbc.JdbcWrapper
com.clickhouse.jdbc.internal.ClickHouseStatementImpl
com.clickhouse.jdbc.internal.AbstractPreparedStatement
com.clickhouse.jdbc.internal.StreamBasedPreparedStatement
- All Implemented Interfaces:
com.clickhouse.config.ClickHouseConfigChangeListener<com.clickhouse.client.ClickHouseRequest<?>>,ClickHousePreparedStatement,ClickHouseStatement,AutoCloseable,PreparedStatement,Statement,Wrapper
public class StreamBasedPreparedStatement
extends AbstractPreparedStatement
implements ClickHousePreparedStatement
-
Field Summary
Fields inherited from class com.clickhouse.jdbc.internal.ClickHouseStatementImpl
mapper, parsedStmtsFields 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
ConstructorsModifierConstructorDescriptionprotectedStreamBasedPreparedStatement(ClickHouseConnectionImpl connection, com.clickhouse.client.ClickHouseRequest<?> request, ClickHouseSqlStatement parsedStmt, int resultSetType, int resultSetConcurrency, int resultSetHoldability) -
Method Summary
Modifier and TypeMethodDescriptionvoidaddBatch()voidvoidprotected voidbooleanexecute()protected long[]executeAny(boolean asBatch) longprotected intprotected StringgetSql()voidvoidsetBigDecimal(int parameterIndex, BigDecimal x) voidsetBinaryStream(int parameterIndex, InputStream x) voidsetByte(int parameterIndex, byte x) voidsetBytes(int parameterIndex, byte[] x) voidvoidsetDouble(int parameterIndex, double x) voidsetFloat(int parameterIndex, float x) voidsetInt(int parameterIndex, int x) voidsetLong(int parameterIndex, long x) voidvoidvoidvoidsetShort(int parameterIndex, short x) voidvoidvoidsetTimestamp(int parameterIndex, Timestamp x, Calendar cal) Methods inherited from class com.clickhouse.jdbc.internal.AbstractPreparedStatement
addBatch, execute, execute, execute, execute, executeLargeBatch, executeLargeUpdate, executeLargeUpdate, executeLargeUpdate, executeLargeUpdate, executeQuery, executeUpdate, executeUpdate, executeUpdate, executeUpdate, executeUpdate, toArrayIndexMethods inherited from class com.clickhouse.jdbc.internal.ClickHouseStatementImpl
cancel, clearWarnings, close, closeOnCompletion, ensureOpen, executeBatch, executeInsert, executeStatement, executeStatement, getConfig, getConnection, getDataProcessor, getDataProcessor, getFetchDirection, getFetchSize, getFile, getGeneratedKeys, getLargeMaxRows, getLargeUpdateCount, getLastStatement, getMaxFieldSize, getMaxRows, getMoreResults, getMoreResults, getNullAsDefault, getQueryTimeout, getRequest, getResultSet, getResultSetConcurrency, getResultSetHoldability, getResultSetType, getUpdateCount, getWarnings, isClosed, isCloseOnCompletion, isPoolable, isWrapperFor, newEmptyResultSet, optionChanged, parseSqlStatements, processSqlStatement, resetDataProcessor, setCursorName, setEscapeProcessing, setFetchDirection, setFetchSize, setLargeMaxRows, setLastStatement, setMaxFieldSize, setMaxRows, setNullAsDefault, setPoolable, setQueryTimeout, settingChanged, unwrap, updateResultMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface com.clickhouse.config.ClickHouseConfigChangeListener
propertyChangedMethods inherited from interface com.clickhouse.jdbc.ClickHousePreparedStatement
getMetaData, setAsciiStream, setAsciiStream, setAsciiStream, setBinaryStream, setBinaryStream, setBlob, setBlob, setBlob, setBoolean, setCharacterStream, setCharacterStream, setCharacterStream, setClob, setClob, setClob, setDate, setNCharacterStream, setNCharacterStream, setNClob, setNClob, setNClob, setNString, setNull, setObject, setRef, setRowId, setSQLXML, setTime, setTimestamp, setUnicodeStream, setURLMethods inherited from interface com.clickhouse.jdbc.ClickHouseStatement
writeMethods inherited from interface java.sql.PreparedStatement
executeUpdate, setObject, setObjectMethods inherited from interface java.sql.Statement
addBatch, cancel, clearWarnings, close, closeOnCompletion, enquoteIdentifier, enquoteLiteral, enquoteNCharLiteral, execute, execute, execute, execute, executeBatch, executeLargeBatch, 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, setQueryTimeoutMethods inherited from interface java.sql.Wrapper
isWrapperFor, unwrap
-
Constructor Details
-
StreamBasedPreparedStatement
protected StreamBasedPreparedStatement(ClickHouseConnectionImpl connection, com.clickhouse.client.ClickHouseRequest<?> request, ClickHouseSqlStatement parsedStmt, int resultSetType, int resultSetConcurrency, int resultSetHoldability) throws SQLException - Throws:
SQLException
-
-
Method Details
-
ensureParams
- Throws:
SQLException
-
executeAny
- Specified by:
executeAnyin classAbstractPreparedStatement- Throws:
SQLException
-
getMaxParameterIndex
protected int getMaxParameterIndex()- Specified by:
getMaxParameterIndexin classAbstractPreparedStatement
-
getSql
-
executeQuery
- Specified by:
executeQueryin interfacePreparedStatement- Throws:
SQLException
-
executeLargeUpdate
- Specified by:
executeLargeUpdatein interfacePreparedStatement- Throws:
SQLException
-
setByte
- Specified by:
setBytein interfacePreparedStatement- Throws:
SQLException
-
setShort
- Specified by:
setShortin interfacePreparedStatement- Throws:
SQLException
-
setInt
- Specified by:
setIntin interfacePreparedStatement- Throws:
SQLException
-
setLong
- Specified by:
setLongin interfacePreparedStatement- Throws:
SQLException
-
setFloat
- Specified by:
setFloatin interfacePreparedStatement- Throws:
SQLException
-
setDouble
- Specified by:
setDoublein interfacePreparedStatement- Throws:
SQLException
-
setBigDecimal
- Specified by:
setBigDecimalin interfacePreparedStatement- Throws:
SQLException
-
setString
- Specified by:
setStringin interfacePreparedStatement- Throws:
SQLException
-
setBytes
- Specified by:
setBytesin interfacePreparedStatement- Throws:
SQLException
-
setBinaryStream
- Specified by:
setBinaryStreamin interfaceClickHousePreparedStatement- Specified by:
setBinaryStreamin interfacePreparedStatement- Throws:
SQLException
-
clearParameters
- Specified by:
clearParametersin interfacePreparedStatement- Throws:
SQLException
-
setObject
- Specified by:
setObjectin interfacePreparedStatement- Throws:
SQLException
-
execute
- Specified by:
executein interfacePreparedStatement- Throws:
SQLException
-
addBatch
- Specified by:
addBatchin interfacePreparedStatement- Throws:
SQLException
-
clearBatch
- Specified by:
clearBatchin interfaceStatement- Overrides:
clearBatchin classClickHouseStatementImpl- Throws:
SQLException
-
setArray
- Specified by:
setArrayin interfacePreparedStatement- Throws:
SQLException
-
setDate
- Specified by:
setDatein interfacePreparedStatement- Throws:
SQLException
-
setTime
- Specified by:
setTimein interfacePreparedStatement- Throws:
SQLException
-
setTimestamp
- Specified by:
setTimestampin interfacePreparedStatement- Throws:
SQLException
-
setNull
- Specified by:
setNullin interfacePreparedStatement- Throws:
SQLException
-
getParameterMetaData
- Specified by:
getParameterMetaDatain interfacePreparedStatement- Throws:
SQLException
-
setObject
public void setObject(int parameterIndex, Object x, int targetSqlType, int scaleOrLength) throws SQLException - Specified by:
setObjectin interfacePreparedStatement- Throws:
SQLException
-