public class BatchedQuery extends Object implements YdbPreparedQuery
| Modifier | Constructor and Description |
|---|---|
protected |
BatchedQuery(String yql,
String listName,
List<String> paramNames,
Map<String,tech.ydb.table.values.Type> types) |
| Modifier and Type | Method and Description |
|---|---|
void |
addBatch() |
int |
batchSize() |
void |
clearBatch() |
void |
clearParameters() |
static BatchedQuery |
createAutoBatched(YqlBatcher batcher,
tech.ydb.table.description.TableDescription description) |
protected List<tech.ydb.table.values.StructValue> |
getBatchedValues() |
List<tech.ydb.table.query.Params> |
getBatchParams() |
tech.ydb.table.query.Params |
getCurrentParams() |
protected tech.ydb.table.values.StructValue |
getCurrentValues() |
TypeDescription |
getDescription(int index) |
String |
getNameByIndex(int index) |
String |
getQueryText(tech.ydb.table.query.Params prms) |
int |
parametersCount() |
void |
setParam(int index,
Object obj,
int sqlType) |
void |
setParam(String name,
Object obj,
int sqlType) |
static BatchedQuery |
tryCreateBatched(YdbQuery query,
Map<String,tech.ydb.table.values.Type> preparedTypes) |
protected BatchedQuery(String yql, String listName, List<String> paramNames, Map<String,tech.ydb.table.values.Type> types) throws SQLException
SQLExceptionpublic String getQueryText(tech.ydb.table.query.Params prms)
getQueryText in interface YdbPreparedQuerypublic int parametersCount()
parametersCount in interface YdbPreparedQuerypublic int batchSize()
batchSize in interface YdbPreparedQuerypublic void clearParameters()
clearParameters in interface YdbPreparedQuerypublic void addBatch()
throws SQLException
addBatch in interface YdbPreparedQuerySQLExceptionpublic void clearBatch()
clearBatch in interface YdbPreparedQueryprotected tech.ydb.table.values.StructValue getCurrentValues()
throws SQLException
SQLExceptionprotected List<tech.ydb.table.values.StructValue> getBatchedValues()
public tech.ydb.table.query.Params getCurrentParams()
throws SQLException
getCurrentParams in interface YdbPreparedQuerySQLExceptionpublic List<tech.ydb.table.query.Params> getBatchParams()
getBatchParams in interface YdbPreparedQuerypublic void setParam(int index,
Object obj,
int sqlType)
throws SQLException
setParam in interface YdbPreparedQuerySQLExceptionpublic void setParam(String name, Object obj, int sqlType) throws SQLException
setParam in interface YdbPreparedQuerySQLExceptionpublic String getNameByIndex(int index) throws SQLException
getNameByIndex in interface YdbPreparedQuerySQLExceptionpublic TypeDescription getDescription(int index) throws SQLException
getDescription in interface YdbPreparedQuerySQLExceptionpublic static BatchedQuery tryCreateBatched(YdbQuery query, Map<String,tech.ydb.table.values.Type> preparedTypes) throws SQLException
SQLExceptionpublic static BatchedQuery createAutoBatched(YqlBatcher batcher, tech.ydb.table.description.TableDescription description) throws SQLException
SQLExceptionCopyright © 2024. All rights reserved.