From: Humberto Dias Date: Sun, 2 May 2021 16:31:24 +0000 (-0300) Subject: Fix for Oracle column default value (#35) X-Git-Tag: release-2.2.1~7 X-Git-Url: https://source.dussan.org/?a=commitdiff_plain;h=897b5133828a15a5e506ae475e1793805aa05cfc;p=iciql.git Fix for Oracle column default value (#35) * Fix for MySql driver class name * Fix for Oracle Column with Default Value * Revert "Fix for MySql driver class name" This reverts commit 66077fcb5a03fb01ae6b11ed6eaba56f2b246b44. Co-authored-by: Humberto Dias --- diff --git a/src/main/java/com/iciql/TableInspector.java b/src/main/java/com/iciql/TableInspector.java index 02bb8ae..207b3c6 100644 --- a/src/main/java/com/iciql/TableInspector.java +++ b/src/main/java/com/iciql/TableInspector.java @@ -163,7 +163,9 @@ public class TableInspector { } } if (!col.isAutoIncrement) { - col.defaultValue = rs.getString("COLUMN_DEF"); + if(rs.getType() != ResultSet.TYPE_FORWARD_ONLY) { + col.defaultValue = rs.getString("COLUMN_DEF"); + } } columns.put(col.name.toLowerCase(), col); }