SELECT - the generic typeINSERT - the generic typeUPDATE - the generic typeDELETE - the generic typeCREATE - the generic typeDROP - the generic typeNEXT - the generic typepublic interface ISqlDialect<SELECT extends SelectBuilder,INSERT extends InsertBuilder,UPDATE extends UpdateBuilder,DELETE extends DeleteBuilder,CREATE extends CreateBranchingBuilder,DROP extends DropBranchingBuilder,NEXT extends NextValueSequenceBuilder,LAST extends LastValueIdentityBuilder> extends ISqlFactory<SELECT,INSERT,UPDATE,DELETE,CREATE,DROP,NEXT,LAST>, ISqlKeywords
ALTER, CLOSE, COMMA, EQUALS, FUNCTION_CURRENT_DATE, FUNCTION_CURRENT_TIME, FUNCTION_CURRENT_TIMESTAMP, KEYWORD_AND, KEYWORD_AS, KEYWORD_ASC, KEYWORD_CHECK, KEYWORD_COLUMN, KEYWORD_CONSTRAINT, KEYWORD_CREATE, KEYWORD_DELETE, KEYWORD_DESC, KEYWORD_DISTINCT, KEYWORD_DROP, KEYWORD_FETCH, KEYWORD_FOR_UPDATE, KEYWORD_FOREIGN, KEYWORD_FROM, KEYWORD_FULL, KEYWORD_GROUP_BY, KEYWORD_HAVING, KEYWORD_IDENTITY, KEYWORD_INDEX, KEYWORD_INNER, KEYWORD_INSERT, KEYWORD_INTO, KEYWORD_JOIN, KEYWORD_KEY, KEYWORD_LEFT, KEYWORD_LIMIT, KEYWORD_NEXT, KEYWORD_NEXT_VALUE_FOR, KEYWORD_NOT, KEYWORD_NULL, KEYWORD_OFFSET, KEYWORD_ON, KEYWORD_ONLY, KEYWORD_OR, KEYWORD_ORDER_BY, KEYWORD_OUTER, KEYWORD_PRIMARY, KEYWORD_REFERENCES, KEYWORD_RIGHT, KEYWORD_ROWS, KEYWORD_SELECT, KEYWORD_SEQUENCE, KEYWORD_SET, KEYWORD_START, KEYWORD_TABLE, KEYWORD_UNION, KEYWORD_UNIQUE, KEYWORD_UPDATE, KEYWORD_VALUES, KEYWORD_VIEW, KEYWORD_WHERE, KEYWORD_WITH, METADATA_ALIAS, METADATA_GLOBAL_TEMPORARY, METADATA_LOCAL_TEMPORARY, METADATA_SYNONYM, METADATA_SYSTEM_TABLE, METADATA_TABLE, METADATA_TABLE_TYPES, METADATA_VIEW, OPEN, QUESTION, SPACE, STAR, TABLE, UNDERSCROE| Modifier and Type | Method and Description |
|---|---|
int |
count(Connection connection,
String table)
Returns the count of rows in the given table.
|
boolean |
exists(Connection connection,
String table)
Check existence of a table.
|
String |
functionCurrentDate()
Gives the dialect specific name of the CURRENT_DATE function.
|
String |
functionCurrentTime()
Gives the dialect specific name of the CURRENT_TIME function.
|
String |
functionCurrentTimestamp()
Gives the dialect specific name of the CURRENT_TIMESTAMP function.
|
String |
getDatabaseName(Connection connection)
Returns the database name
|
String |
getDataTypeName(DataType dataType)
Default implementation returns the direct toString() conversion.
|
String |
getIdentityArgument()
Identity argument for a column for the create table script Default is
"IDENTITY".
|
String |
getNotNullArgument()
NOT NULL argument for a column for the create table script Default is
"NOT NULL".
|
String |
getPrimaryKeyArgument()
PRIMARY KEY argument for a column for the create table script Default is
"PRIMARY KEY".
|
String |
getSchemaFilterScript()
If the database supports schema filtering SQL statements (see
isSchemaFilterSupported()), this method provides the
corresponding SQL statement. |
String |
getUniqueArgument()
UNIQUE argument for a column for the create table script Default is
"UNIQUE".
|
boolean |
isCatalogForSchema()
Does this database support catalogs synonymous to schemas.
|
boolean |
isSchemaFilterSupported()
Checks if the database is capable of schema-level filtering statements
(e.g.
|
boolean |
isSequenceSupported()
Checks if the database is capable to create and use Sequences.
|
create, delete, drop, expression, insert, lastval, nextval, select, updateString getDataTypeName(DataType dataType)
dataType - the data typeString getPrimaryKeyArgument()
String getIdentityArgument()
String getNotNullArgument()
String getUniqueArgument()
boolean exists(Connection connection, String table) throws SQLException
exists in interface ISqlFactory<SELECT extends SelectBuilder,INSERT extends InsertBuilder,UPDATE extends UpdateBuilder,DELETE extends DeleteBuilder,CREATE extends CreateBranchingBuilder,DROP extends DropBranchingBuilder,NEXT extends NextValueSequenceBuilder,LAST extends LastValueIdentityBuilder>connection - the current connectiontable - the table nameSQLException - the SQL exceptionint count(Connection connection, String table) throws SQLException
count in interface ISqlFactory<SELECT extends SelectBuilder,INSERT extends InsertBuilder,UPDATE extends UpdateBuilder,DELETE extends DeleteBuilder,CREATE extends CreateBranchingBuilder,DROP extends DropBranchingBuilder,NEXT extends NextValueSequenceBuilder,LAST extends LastValueIdentityBuilder>connection - the current connectiontable - the table nameSQLException - the SQL exceptionboolean isSchemaFilterSupported()
String getSchemaFilterScript()
isSchemaFilterSupported()), this method provides the
corresponding SQL statement.boolean isCatalogForSchema()
String functionCurrentDate()
String functionCurrentTime()
String functionCurrentTimestamp()
boolean isSequenceSupported()
String getDatabaseName(Connection connection)
connection - the active database connectionCopyright © 2010–2018 Eclipse Foundation. All rights reserved.