sqoop-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jar...@apache.org
Subject sqoop git commit: SQOOP-2018: GenericJDBCConnector SqlTypes INTEGER should be set 4 bytes
Date Thu, 15 Jan 2015 15:58:14 GMT
Repository: sqoop
Updated Branches:
  refs/heads/sqoop2 819b13802 -> 308365bbf


SQOOP-2018: GenericJDBCConnector SqlTypes INTEGER should be set 4 bytes

(Veena Basavaraj via Jarek Jarcec Cecho)


Project: http://git-wip-us.apache.org/repos/asf/sqoop/repo
Commit: http://git-wip-us.apache.org/repos/asf/sqoop/commit/308365bb
Tree: http://git-wip-us.apache.org/repos/asf/sqoop/tree/308365bb
Diff: http://git-wip-us.apache.org/repos/asf/sqoop/diff/308365bb

Branch: refs/heads/sqoop2
Commit: 308365bbf2d39132e6cf27fe52eaf2fdeb483007
Parents: 819b138
Author: Jarek Jarcec Cecho <jarcec@apache.org>
Authored: Thu Jan 15 07:57:51 2015 -0800
Committer: Jarek Jarcec Cecho <jarcec@apache.org>
Committed: Thu Jan 15 07:57:51 2015 -0800

----------------------------------------------------------------------
 .../java/org/apache/sqoop/connector/jdbc/util/SqlTypesUtils.java  | 3 ++-
 .../java/org/apache/sqoop/connector/jdbc/TestFromInitializer.java | 2 +-
 2 files changed, 3 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/sqoop/blob/308365bb/connector/connector-generic-jdbc/src/main/java/org/apache/sqoop/connector/jdbc/util/SqlTypesUtils.java
----------------------------------------------------------------------
diff --git a/connector/connector-generic-jdbc/src/main/java/org/apache/sqoop/connector/jdbc/util/SqlTypesUtils.java
b/connector/connector-generic-jdbc/src/main/java/org/apache/sqoop/connector/jdbc/util/SqlTypesUtils.java
index c0ca7f2..8228397 100644
--- a/connector/connector-generic-jdbc/src/main/java/org/apache/sqoop/connector/jdbc/util/SqlTypesUtils.java
+++ b/connector/connector-generic-jdbc/src/main/java/org/apache/sqoop/connector/jdbc/util/SqlTypesUtils.java
@@ -48,8 +48,9 @@ public class SqlTypesUtils {
     switch (sqlType) {
       case Types.SMALLINT:
       case Types.TINYINT:
-      case Types.INTEGER:
         return new FixedPoint(columnName).setByteSize(2L);
+      case Types.INTEGER:
+        return new FixedPoint(columnName).setByteSize(4L);
 
       case Types.CLOB:
       case Types.VARCHAR:

http://git-wip-us.apache.org/repos/asf/sqoop/blob/308365bb/connector/connector-generic-jdbc/src/test/java/org/apache/sqoop/connector/jdbc/TestFromInitializer.java
----------------------------------------------------------------------
diff --git a/connector/connector-generic-jdbc/src/test/java/org/apache/sqoop/connector/jdbc/TestFromInitializer.java
b/connector/connector-generic-jdbc/src/test/java/org/apache/sqoop/connector/jdbc/TestFromInitializer.java
index 29a528b..249cd34 100644
--- a/connector/connector-generic-jdbc/src/test/java/org/apache/sqoop/connector/jdbc/TestFromInitializer.java
+++ b/connector/connector-generic-jdbc/src/test/java/org/apache/sqoop/connector/jdbc/TestFromInitializer.java
@@ -102,7 +102,7 @@ public class TestFromInitializer {
    */
   public Schema getSchema(String name) {
     return new Schema(name)
-      .addColumn(new FixedPoint("ICOL").setByteSize(2L))
+      .addColumn(new FixedPoint("ICOL").setByteSize(4L))
       .addColumn(new FloatingPoint("DCOL"))
       .addColumn(new Text("VCOL"))
     ;


Mime
View raw message