public class ClickHouseStatement extends Object implements SQLStatement
| Modifier and Type | Field and Description |
|---|---|
protected Block |
block |
protected ClickHouseConnection |
connection |
protected NativeContext |
nativeContext |
CLOSE_ALL_RESULTS, CLOSE_CURRENT_RESULT, EXECUTE_FAILED, KEEP_CURRENT_RESULT, NO_GENERATED_KEYS, RETURN_GENERATED_KEYS, SUCCESS_NO_INFO| Constructor and Description |
|---|
ClickHouseStatement(ClickHouseConnection connection,
NativeContext nativeContext) |
| Modifier and Type | Method and Description |
|---|---|
void |
cancel() |
void |
clearWarnings() |
void |
close() |
boolean |
execute(String query) |
ResultSet |
executeQuery(String query) |
int |
executeUpdate(String query) |
Connection |
getConnection() |
int |
getFetchDirection() |
int |
getFetchSize() |
ResultSet |
getGeneratedKeys() |
int |
getMaxRows() |
boolean |
getMoreResults() |
int |
getQueryTimeout() |
ResultSet |
getResultSet() |
int |
getResultSetConcurrency() |
int |
getResultSetHoldability() |
int |
getResultSetType() |
protected Block |
getSampleBlock(String insertQuery) |
int |
getUpdateCount() |
SQLWarning |
getWarnings() |
boolean |
isClosed() |
boolean |
isPoolable() |
Logger |
logger() |
void |
setCursorName(String name) |
void |
setEscapeProcessing(boolean enable) |
void |
setFetchDirection(int direction) |
void |
setFetchSize(int rows) |
void |
setMaxRows(int max) |
void |
setPoolable(boolean poolable) |
void |
setQueryTimeout(int seconds) |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitaddBatch, clearBatch, closeOnCompletion, execute, execute, execute, executeBatch, executeLargeBatch, executeLargeUpdate, executeLargeUpdate, executeLargeUpdate, executeLargeUpdate, executeUpdate, executeUpdate, executeUpdate, getLargeMaxRows, getLargeUpdateCount, getMaxFieldSize, getMoreResults, isCloseOnCompletion, setLargeMaxRows, setMaxFieldSizeisWrapperFor, unwrapprotected Block block
protected final ClickHouseConnection connection
protected final NativeContext nativeContext
public ClickHouseStatement(ClickHouseConnection connection, NativeContext nativeContext)
public boolean execute(String query) throws SQLException
execute in interface SQLStatementexecute in interface StatementSQLExceptionpublic int executeUpdate(String query) throws SQLException
executeUpdate in interface SQLStatementexecuteUpdate in interface StatementSQLExceptionpublic ResultSet executeQuery(String query) throws SQLException
executeQuery in interface SQLStatementexecuteQuery in interface StatementSQLExceptionpublic int getUpdateCount()
throws SQLException
getUpdateCount in interface SQLStatementgetUpdateCount in interface StatementSQLExceptionpublic ResultSet getResultSet()
getResultSet in interface SQLStatementgetResultSet in interface Statementpublic boolean getMoreResults()
throws SQLException
getMoreResults in interface SQLStatementgetMoreResults in interface StatementSQLExceptionpublic void close()
throws SQLException
close in interface SQLStatementclose in interface AutoCloseableclose in interface StatementSQLExceptionpublic boolean isClosed()
throws SQLException
isClosed in interface SQLStatementisClosed in interface StatementSQLExceptionpublic void cancel()
throws SQLException
cancel in interface SQLStatementcancel in interface StatementSQLExceptionpublic int getMaxRows()
throws SQLException
getMaxRows in interface SQLStatementgetMaxRows in interface StatementSQLExceptionpublic void setMaxRows(int max)
throws SQLException
setMaxRows in interface SQLStatementsetMaxRows in interface StatementSQLExceptionpublic int getQueryTimeout()
getQueryTimeout in interface SQLStatementgetQueryTimeout in interface Statementpublic void setQueryTimeout(int seconds)
setQueryTimeout in interface SQLStatementsetQueryTimeout in interface Statementpublic void setFetchDirection(int direction)
throws SQLException
setFetchDirection in interface SQLStatementsetFetchDirection in interface StatementSQLExceptionpublic int getFetchDirection()
throws SQLException
getFetchDirection in interface SQLStatementgetFetchDirection in interface StatementSQLExceptionpublic void setFetchSize(int rows)
throws SQLException
setFetchSize in interface SQLStatementsetFetchSize in interface StatementSQLExceptionpublic int getFetchSize()
throws SQLException
getFetchSize in interface SQLStatementgetFetchSize in interface StatementSQLExceptionpublic void setPoolable(boolean poolable)
throws SQLException
setPoolable in interface SQLStatementsetPoolable in interface StatementSQLExceptionpublic boolean isPoolable()
throws SQLException
isPoolable in interface SQLStatementisPoolable in interface StatementSQLExceptionpublic int getResultSetConcurrency()
throws SQLException
getResultSetConcurrency in interface SQLStatementgetResultSetConcurrency in interface StatementSQLExceptionpublic int getResultSetType()
throws SQLException
getResultSetType in interface SQLStatementgetResultSetType in interface StatementSQLExceptionpublic ResultSet getGeneratedKeys() throws SQLException
getGeneratedKeys in interface SQLStatementgetGeneratedKeys in interface StatementSQLExceptionpublic Connection getConnection()
getConnection in interface SQLStatementgetConnection in interface Statementpublic void setEscapeProcessing(boolean enable)
throws SQLException
setEscapeProcessing in interface SQLStatementsetEscapeProcessing in interface StatementSQLExceptionpublic SQLWarning getWarnings() throws SQLException
getWarnings in interface SQLStatementgetWarnings in interface StatementSQLExceptionpublic void clearWarnings()
throws SQLException
clearWarnings in interface SQLStatementclearWarnings in interface StatementSQLExceptionpublic void setCursorName(String name) throws SQLException
setCursorName in interface SQLStatementsetCursorName in interface StatementSQLExceptionpublic int getResultSetHoldability()
throws SQLException
getResultSetHoldability in interface SQLStatementgetResultSetHoldability in interface StatementSQLExceptionprotected Block getSampleBlock(String insertQuery) throws SQLException
SQLExceptionCopyright © 2021. All rights reserved.