diff options
author | James Moger <james.moger@gmail.com> | 2011-08-16 15:32:56 -0400 |
---|---|---|
committer | James Moger <james.moger@gmail.com> | 2011-08-16 15:32:56 -0400 |
commit | d95e16170d063c0b74d04e6636e8fddbfa120689 (patch) | |
tree | a8157992ef14cb8f4392b847fbc8892cb30245d5 /src/com/iciql/SQLDialectDefault.java | |
parent | 8193609af00aa9529ed7b3090b5739c4e95b12c4 (diff) | |
download | iciql-d95e16170d063c0b74d04e6636e8fddbfa120689.tar.gz iciql-d95e16170d063c0b74d04e6636e8fddbfa120689.zip |
Finished MySQL dialect; v5.0.51b 100% tested. Added Db.dropTable(T)
Diffstat (limited to 'src/com/iciql/SQLDialectDefault.java')
-rw-r--r-- | src/com/iciql/SQLDialectDefault.java | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/src/com/iciql/SQLDialectDefault.java b/src/com/iciql/SQLDialectDefault.java index 69502c3..0b611e0 100644 --- a/src/com/iciql/SQLDialectDefault.java +++ b/src/com/iciql/SQLDialectDefault.java @@ -57,7 +57,8 @@ public class SQLDialectDefault implements SQLDialect { * @param sqlType
* @return the SQL type or a preferred alternative
*/
- protected String convertSqlType(String sqlType) {
+ @Override
+ public String convertSqlType(String sqlType) {
return sqlType;
}
@@ -95,6 +96,14 @@ public class SQLDialectDefault implements SQLDialect { }
@Override
+ public <T> void prepareDropTable(SQLStatement stat, TableDefinition<T> def) {
+ StatementBuilder buff = new StatementBuilder("DROP TABLE IF EXISTS "
+ + prepareTableName(def.schemaName, def.tableName));
+ stat.setSQL(buff.toString());
+ return;
+ }
+
+ @Override
public <T> void prepareCreateTable(SQLStatement stat, TableDefinition<T> def) {
StatementBuilder buff;
if (def.memoryTable && supportsMemoryTables()) {
|