类 PostgreSQLDialect
java.lang.Object
cn.featherfly.common.db.dialect.AbstractDialect
cn.featherfly.common.db.dialect.PostgreSQLDialect
- 所有已实现的接口:
Dialect
public class PostgreSQLDialect extends AbstractDialect
PostgreSQL Dialect.
-
嵌套类概要
从接口继承的嵌套类/接口 cn.featherfly.common.db.dialect.Dialect
Dialect.Keyworld -
字段概要
从类继承的字段 cn.featherfly.common.db.dialect.AbstractDialect
logger, UPDATE_STRING从接口继承的字段 cn.featherfly.common.db.dialect.Dialect
DEFAULT_LIMIT, LIMIT_PARAM_NAME, PARAM_NAME_START_SYMBOL, PRIMARY_KEY_INDEX_NAME, START_PARAM_NAME -
构造器概要
构造器 构造器 说明 PostgreSQLDialect()Instantiates a new postgre SQL dialect. -
方法概要
修饰符和类型 方法 说明 java.lang.StringbuildCreateTableDDL(Table table)Builds the create table sql.java.lang.StringconvertValueToSql(java.lang.Object value, int sqlType)转换值为字符串protected java.lang.StringgetAutoIncrement(Column column)Gets the identity.protected java.lang.StringgetColumnDDL(Column column)Gets the column DDL.java.lang.StringgetColumnTypeName(java.sql.SQLType sqlType)Gets the column type name.java.lang.StringgetInitSqlFooter()Gets the inits the sql footer.java.lang.StringgetInitSqlHeader()Gets the inits the sql header.java.lang.StringgetPaginationSql(java.lang.String sql, int start, int limit)转换普通sql为带分页的sqljava.lang.Object[]getPaginationSqlParameter(java.lang.Object[] params, int start, int limit)返回分页参数的数组java.lang.StringgetParamNamedPaginationSql(java.lang.String sql, int start, int limit)转换普通命名sql为带分页的sql,此sql为带命名参数sql, 如select * from user where user_name = :usernamejava.lang.StringgetParamNamedPaginationSql(java.lang.String sql, int start, int limit, char startSymbol)转换普通命名sql为带分页的sql,此sql为带命名参数sql, 如select * from user where user_name = {startSymal}username.protected java.lang.StringgetPrimaryKeyDDL(Table table)Gets the primary key DDL.protected java.lang.StringgetTableComment(Table table)Gets the table comment.java.lang.StringgetWrapSign()Gets the wrap sign.java.lang.StringwrapName(java.lang.String name)包装名称,避免关键字问题从类继承的方法 cn.featherfly.common.db.dialect.AbstractDialect
buildAddColumnDDL, buildAlterTableAddColumnDDL, buildAlterTableDDL, buildAlterTableDropColumnDDL, buildAlterTableDropColumnDDL, buildAlterTableModifyColumnDDL, buildDropColumnDDL, buildDropColumnDDL, buildModifyColumnDDL, getColumnComment, getColumnNotNull, getColumnTypeDDL, getColumnTypeDDL, getDefaultValue, getKeywords, getPaginationSqlParameter, getTableColumnsDDL, isForUpdate, isKeywordsUppercase, isTableAndColumnNameUppercase, setKeywordsUppercase, setTableAndColumnNameUppercase, valueToSql从类继承的方法 java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait从接口继承的方法 cn.featherfly.common.db.dialect.Dialect
buildAlterTableAddColumnDDL, buildAlterTableDDL, buildAlterTableDDL, buildAlterTableDropColumnDDL, buildAlterTableDropColumnDDL, buildAlterTableModifyColumnDDL, buildColumnSql, buildColumnSql, buildColumnSql, buildColumnSql, buildColumnSql, buildColumnSql, buildColumnSql, buildCreateDataBaseDDL, buildCreateIndexDDL, buildCreateIndexDDL, buildCreateIndexDDL, buildCreateIndexDDL, buildCreateSchemaDDL, buildDropDataBaseDDL, buildDropDataBaseDDL, buildDropDDL, buildDropIndexDDL, buildDropIndexDDL, buildDropIndexDDL, buildDropIndexDDL, buildDropSchemaDDL, buildDropSchemaDDL, buildDropTableDDL, buildDropTableDDL, buildDropTableDDL, buildDropTableDDL, buildDropTableDDL, buildDropViewDDL, buildDropViewDDL, buildDropViewDDL, buildInsertBatchSql, buildTableSql, buildTableSql, buildTableSql, convertTableOrColumnName, getDefaultSchema, getDefaultSize, getFunction, getKeyword, getKeyword, getKeyword, getPrimaryKeyIndexName, isAutoGenerateKeyBatch, isInsertBatch
-
构造器详细资料
-
PostgreSQLDialect
public PostgreSQLDialect()Instantiates a new postgre SQL dialect.
-
-
方法详细资料
-
getPaginationSql
public java.lang.String getPaginationSql(java.lang.String sql, int start, int limit)转换普通sql为带分页的sql
.- 参数:
sql- 带转换的sqlstart- 起始数limit- 数量- 返回:
- 返回转换好的分页sql
-
getParamNamedPaginationSql
public java.lang.String getParamNamedPaginationSql(java.lang.String sql, int start, int limit)转换普通命名sql为带分页的sql,此sql为带命名参数sql, 如select * from user where user_name = :username
.- 参数:
sql- 带转换的sqlstart- 起始数limit- 数量- 返回:
- 返回转换好的分页sql
-
getParamNamedPaginationSql
public java.lang.String getParamNamedPaginationSql(java.lang.String sql, int start, int limit, char startSymbol)转换普通命名sql为带分页的sql,此sql为带命名参数sql, 如select * from user where user_name = {startSymal}username.
.- 参数:
sql- 带转换的sqlstart- 起始数limit- 数量startSymbol- 命名参数的起始符号- 返回:
- 返回转换好的分页sql
-
getPaginationSqlParameter
public java.lang.Object[] getPaginationSqlParameter(java.lang.Object[] params, int start, int limit)返回分页参数的数组
.- 指定者:
getPaginationSqlParameter在接口中Dialect- 覆盖:
getPaginationSqlParameter在类中AbstractDialect- 参数:
params- 参数数组start- 起始数limit- 数量- 返回:
- 分页参数的数组
-
convertValueToSql
public java.lang.String convertValueToSql(java.lang.Object value, int sqlType)转换值为字符串
.- 指定者:
convertValueToSql在类中AbstractDialect- 参数:
value- valuesqlType- sqlType- 返回:
- 字符串
-
wrapName
public java.lang.String wrapName(java.lang.String name)包装名称,避免关键字问题
.- 参数:
name- 名称(列明,表名等)- 返回:
- 包装后的名称
-
getWrapSign
public java.lang.String getWrapSign()Gets the wrap sign.- 返回:
- the wrap sign
-
buildCreateTableDDL
Builds the create table sql.- 指定者:
buildCreateTableDDL在接口中Dialect- 覆盖:
buildCreateTableDDL在类中AbstractDialect- 参数:
table- the table- 返回:
- the string
-
getTableComment
Gets the table comment.- 覆盖:
getTableComment在类中AbstractDialect- 参数:
table- the table- 返回:
- the table comment
-
getPrimaryKeyDDL
Gets the primary key DDL.- 覆盖:
getPrimaryKeyDDL在类中AbstractDialect- 参数:
table- the table- 返回:
- the primary key DDL
-
getColumnDDL
Gets the column DDL.- 覆盖:
getColumnDDL在类中AbstractDialect- 参数:
column- the column- 返回:
- the column DDL
-
getColumnTypeName
public java.lang.String getColumnTypeName(java.sql.SQLType sqlType)Gets the column type name.- 参数:
sqlType- the sql type- 返回:
- the column type name
-
getAutoIncrement
Gets the identity.- 指定者:
getAutoIncrement在类中AbstractDialect- 参数:
column- the column- 返回:
- the identity
-
getInitSqlHeader
public java.lang.String getInitSqlHeader()Gets the inits the sql header.- 返回:
- the inits the sql header
-