diff options
author | Michael Armbrust <michael@databricks.com> | 2014-05-15 16:50:42 -0700 |
---|---|---|
committer | Reynold Xin <rxin@apache.org> | 2014-05-15 16:50:42 -0700 |
commit | a4aafe5f9fb191533400caeafddf04986492c95f (patch) | |
tree | 7300066058b3b8020eb84cc756003d246c4e08bd /sql/hive | |
parent | e66e31be51f396c8f6b7a45119b8b31c4d8cdf79 (diff) | |
download | spark-a4aafe5f9fb191533400caeafddf04986492c95f.tar.gz spark-a4aafe5f9fb191533400caeafddf04986492c95f.tar.bz2 spark-a4aafe5f9fb191533400caeafddf04986492c95f.zip |
[SQL] Fix tiny/small ints from HiveMetastore.
Author: Michael Armbrust <michael@databricks.com>
Closes #797 from marmbrus/smallInt and squashes the following commits:
2db9dae [Michael Armbrust] Fix tiny/small ints from HiveMetastore.
Diffstat (limited to 'sql/hive')
-rw-r--r-- | sql/hive/src/main/scala/org/apache/spark/sql/hive/HiveMetastoreCatalog.scala | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/sql/hive/src/main/scala/org/apache/spark/sql/hive/HiveMetastoreCatalog.scala b/sql/hive/src/main/scala/org/apache/spark/sql/hive/HiveMetastoreCatalog.scala index fa30f596f8..636c4f7b93 100644 --- a/sql/hive/src/main/scala/org/apache/spark/sql/hive/HiveMetastoreCatalog.scala +++ b/sql/hive/src/main/scala/org/apache/spark/sql/hive/HiveMetastoreCatalog.scala @@ -183,7 +183,8 @@ object HiveMetastoreTypes extends RegexParsers { "string" ^^^ StringType | "float" ^^^ FloatType | "int" ^^^ IntegerType | - "tinyint" ^^^ ShortType | + "tinyint" ^^^ ByteType | + "smallint" ^^^ ShortType | "double" ^^^ DoubleType | "bigint" ^^^ LongType | "binary" ^^^ BinaryType | @@ -227,7 +228,8 @@ object HiveMetastoreTypes extends RegexParsers { case StringType => "string" case FloatType => "float" case IntegerType => "int" - case ShortType =>"tinyint" + case ByteType => "tinyint" + case ShortType => "smallint" case DoubleType => "double" case LongType => "bigint" case BinaryType => "binary" |