From 5b1113a29cc76253351616a9893b486b2996ea85 Mon Sep 17 00:00:00 2001 From: James Moger Date: Tue, 30 Aug 2011 16:41:01 -0400 Subject: [PATCH] Adjustment to PostgreSQL dialect for creating autoincrement columns. --- src/com/iciql/SQLDialectPostgreSQL.java | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/src/com/iciql/SQLDialectPostgreSQL.java b/src/com/iciql/SQLDialectPostgreSQL.java index 5b3ec71..fc115ab 100644 --- a/src/com/iciql/SQLDialectPostgreSQL.java +++ b/src/com/iciql/SQLDialectPostgreSQL.java @@ -46,24 +46,22 @@ public class SQLDialectPostgreSQL extends SQLDialectDefault { @Override protected boolean prepareColumnDefinition(StatementBuilder buff, String dataType, - boolean isAutoIncrement, boolean isPrimaryKey) { - boolean isIdentity = false; + boolean isAutoIncrement, boolean isPrimaryKey) { String convertedType = convertSqlType(dataType); if (isIntegerType(dataType)) { - if (isAutoIncrement && isPrimaryKey) { + if (isAutoIncrement) { if ("BIGINT".equals(dataType)) { buff.append("BIGSERIAL"); } else { buff.append("SERIAL"); } - isIdentity = true; } else { buff.append(convertedType); } } else { buff.append(convertedType); } - return isIdentity; + return false; } @Override -- 2.39.5