diff --git a/examples/pig/test/populate-cli.txt b/examples/pig/test/populate-cli.txt index 1f596422b8..b2dda585e2 100644 --- a/examples/pig/test/populate-cli.txt +++ b/examples/pig/test/populate-cli.txt @@ -8,7 +8,7 @@ column_metadata = [ {column_name: name, validation_class: UTF8Type, index_type: KEYS}, {column_name: vote_type, validation_class: UTF8Type}, - {column_name: rating, validation_class: IntegerType}, + {column_name: rating, validation_class: Int32Type}, {column_name: score, validation_class: LongType}, {column_name: percent, validation_class: FloatType}, {column_name: atomic_weight, validation_class: DoubleType}, @@ -23,7 +23,7 @@ column_metadata = [ {column_name: name, validation_class: UTF8Type, index_type: KEYS}, {column_name: vote_type, validation_class: UTF8Type}, - {column_name: rating, validation_class: IntegerType}, + {column_name: rating, validation_class: Int32Type}, {column_name: score, validation_class: LongType}, {column_name: percent, validation_class: FloatType}, {column_name: atomic_weight, validation_class: DoubleType}, diff --git a/src/java/org/apache/cassandra/hadoop/pig/CassandraStorage.java b/src/java/org/apache/cassandra/hadoop/pig/CassandraStorage.java index 454330c025..f2fad67930 100644 --- a/src/java/org/apache/cassandra/hadoop/pig/CassandraStorage.java +++ b/src/java/org/apache/cassandra/hadoop/pig/CassandraStorage.java @@ -670,7 +670,7 @@ public class CassandraStorage extends LoadFunc implements StoreFuncInterface, Lo { if (type instanceof LongType || type instanceof DateType) // DateType is bad and it should feel bad return DataType.LONG; - else if (type instanceof IntegerType) + else if (type instanceof IntegerType || type instanceof Int32Type) // IntegerType will overflow at 2**31, but is kept for compatibility until pig has a BigInteger return DataType.INTEGER; else if (type instanceof AsciiType) return DataType.CHARARRAY;