Browse Source

Fixed order of DEFAULT in create table statement (issue 11)

tags/v1.2.0
James Moger 11 years ago
parent
commit
53bc79dbe4
2 changed files with 5 additions and 4 deletions
  1. 1
    0
      docs/05_releases.mkd
  2. 4
    4
      src/com/iciql/SQLDialectDefault.java

+ 1
- 0
docs/05_releases.mkd View File

@@ -4,6 +4,7 @@
**%VERSION%** ([zip](http://code.google.com/p/iciql/downloads/detail?name=%ZIP%)|[jar](http://code.google.com/p/iciql/downloads/detail?name=%JAR%))   *released %BUILDDATE%*
- Fixed order of DEFAULT value in create table statement (issue 11)
- Fixed password bug in model generator (issue 7)
**1.1.0**   *released 2012-08-20*

+ 4
- 4
src/com/iciql/SQLDialectDefault.java View File

@@ -134,10 +134,6 @@ public class SQLDialectDefault implements SQLDialect {
field.isAutoIncrement, field.isPrimaryKey);
}
if (!field.nullable) {
buff.append(" NOT NULL");
}
// default values
if (!field.isAutoIncrement && !field.isPrimaryKey) {
String dv = field.defaultValue;
@@ -148,6 +144,10 @@ public class SQLDialectDefault implements SQLDialect {
}
}
}
if (!field.nullable) {
buff.append(" NOT NULL");
}
}
// if table does not have identity column then specify primary key

Loading…
Cancel
Save