public interface PipelineSQLBuilder
extends org.apache.shardingsphere.infra.util.spi.type.typed.TypedSPI, org.apache.shardingsphere.infra.util.spi.type.required.RequiredSPI
| 限定符和类型 | 方法和说明 |
|---|---|
String |
buildCheckEmptySQL(String schemaName,
String tableName)
Build check empty SQL.
|
String |
buildChunkedQuerySQL(String schemaName,
String tableName,
String uniqueKey,
boolean firstQuery)
Build query SQL.
|
String |
buildCountSQL(String schemaName,
String tableName)
Build count SQL.
|
default Optional<String> |
buildCRC32SQL(String schemaName,
String tableName,
String column)
Build CRC32 SQL.
|
default Optional<String> |
buildCreateSchemaSQL(String schemaName)
Build create schema SQL.
|
String |
buildDeleteSQL(String schemaName,
DataRecord dataRecord,
Collection<Column> conditionColumns)
Build delete SQL.
|
String |
buildDivisibleInventoryDumpSQL(String schemaName,
String tableName,
String uniqueKey,
int uniqueKeyDataType,
boolean firstQuery)
Build divisible inventory dump first SQL.
|
String |
buildDropSQL(String schemaName,
String tableName)
Build drop SQL.
|
String |
buildIndivisibleInventoryDumpSQL(String schemaName,
String tableName,
String uniqueKey,
int uniqueKeyDataType,
boolean firstQuery)
Build indivisible inventory dump first SQL.
|
String |
buildInsertSQL(String schemaName,
DataRecord dataRecord,
Map<LogicTableName,Set<String>> shardingColumnsMap)
Build insert SQL.
|
String |
buildSplitByPrimaryKeyRangeSQL(String schemaName,
String tableName,
String primaryKey)
Build split by primary key range SQL.
|
String |
buildUpdateSQL(String schemaName,
DataRecord dataRecord,
Collection<Column> conditionColumns,
Map<LogicTableName,Set<String>> shardingColumnsMap)
Build update SQL.
|
List<Column> |
extractUpdatedColumns(DataRecord record,
Map<LogicTableName,Set<String>> shardingColumnsMap)
Extract updated columns.
|
default Optional<String> buildCreateSchemaSQL(String schemaName)
schemaName - schema nameString buildDivisibleInventoryDumpSQL(String schemaName, String tableName, String uniqueKey, int uniqueKeyDataType, boolean firstQuery)
schemaName - schema nametableName - table nameuniqueKey - unique keyuniqueKeyDataType - unique key data typefirstQuery - whether it's the first time queryString buildIndivisibleInventoryDumpSQL(String schemaName, String tableName, String uniqueKey, int uniqueKeyDataType, boolean firstQuery)
schemaName - schema nametableName - table nameuniqueKey - unique keyuniqueKeyDataType - unique key data typefirstQuery - whether it's the first time queryString buildInsertSQL(String schemaName, DataRecord dataRecord, Map<LogicTableName,Set<String>> shardingColumnsMap)
schemaName - schema namedataRecord - data recordshardingColumnsMap - sharding columns mapString buildUpdateSQL(String schemaName, DataRecord dataRecord, Collection<Column> conditionColumns, Map<LogicTableName,Set<String>> shardingColumnsMap)
schemaName - schema namedataRecord - data recordconditionColumns - condition columnsshardingColumnsMap - sharding columns mapList<Column> extractUpdatedColumns(DataRecord record, Map<LogicTableName,Set<String>> shardingColumnsMap)
record - data recordshardingColumnsMap - sharding columns mapString buildDeleteSQL(String schemaName, DataRecord dataRecord, Collection<Column> conditionColumns)
schemaName - schema namedataRecord - data recordconditionColumns - condition columnsString buildDropSQL(String schemaName, String tableName)
schemaName - schema nametableName - table nameString buildCountSQL(String schemaName, String tableName)
schemaName - schema nametableName - table nameString buildChunkedQuerySQL(String schemaName, String tableName, String uniqueKey, boolean firstQuery)
schemaName - schema nametableName - table nameuniqueKey - unique key, it may be primary key, not nullfirstQuery - first queryString buildCheckEmptySQL(String schemaName, String tableName)
schemaName - schema nametableName - table nameString buildSplitByPrimaryKeyRangeSQL(String schemaName, String tableName, String primaryKey)
schemaName - schema nametableName - table nameprimaryKey - primary keyCopyright © 2022 The Apache Software Foundation. All rights reserved.