You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@shardingsphere.apache.org by GitBox <gi...@apache.org> on 2019/11/10 10:52:03 UTC

[GitHub] [incubator-shardingsphere] beijing-penguin commented on a change in pull request #3488: Fix three mistakes

beijing-penguin commented on a change in pull request #3488: Fix three mistakes
URL: https://github.com/apache/incubator-shardingsphere/pull/3488#discussion_r344484860
 
 

 ##########
 File path: sharding-core/sharding-core-execute/src/main/java/org/apache/shardingsphere/core/execute/metadata/TableMetaDataLoader.java
 ##########
 @@ -165,8 +174,9 @@ private boolean isTableExist(final Connection connection, final String catalog,
                 String columnName = resultSet.getString(COLUMN_NAME);
                 String columnType = resultSet.getString(TYPE_NAME);
                 boolean isPrimaryKey = primaryKeys.contains(columnName);
-                boolean isNotNull = isPrimaryKey || !resultSet.getBoolean(IS_NULLABLE);
-                boolean isAutoIncrement = resultSet.getBoolean(IS_AUTOINCREMENT);
+                boolean isNotNull = isPrimaryKey || !resultSet.getString(IS_NULLABLE).equalsIgnoreCase("YES");
+                String autoIncrement = resultSet.getString(IS_AUTOINCREMENT);
+                boolean isAutoIncrement = autoIncrement.equalsIgnoreCase("YES");
 
 Review comment:
   because  IS_NULLABLE and IS_AUTOINCREMENT return type  is String "YES",not boolean..

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services