You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@pig.apache.org by jc...@apache.org on 2012/05/12 00:27:07 UTC
svn commit: r1337400 - in /pig/trunk: CHANGES.txt
src/org/apache/pig/impl/util/NumValCarrier.java
test/org/apache/pig/test/TestSchema.java
Author: jcoveney
Date: Fri May 11 22:27:07 2012
New Revision: 1337400
URL: http://svn.apache.org/viewvc?rev=1337400&view=rev
Log:
PIG-2639: Utils.getSchemaFromString should automatically give name to all types, but fails on boolean (jcoveney)
Modified:
pig/trunk/CHANGES.txt
pig/trunk/src/org/apache/pig/impl/util/NumValCarrier.java
pig/trunk/test/org/apache/pig/test/TestSchema.java
Modified: pig/trunk/CHANGES.txt
URL: http://svn.apache.org/viewvc/pig/trunk/CHANGES.txt?rev=1337400&r1=1337399&r2=1337400&view=diff
==============================================================================
--- pig/trunk/CHANGES.txt (original)
+++ pig/trunk/CHANGES.txt Fri May 11 22:27:07 2012
@@ -24,6 +24,8 @@ INCOMPATIBLE CHANGES
IMPROVEMENTS
+PIG-2639: Utils.getSchemaFromString should automatically give name to all types, but fails on boolean (jcoveney)
+
PIG-2583: Add Grunt command to list the statements in cache (xalan via daijy)
PIG-2688: Log the aliases being processed for the current job (ddaniels888 via azaroth)
Modified: pig/trunk/src/org/apache/pig/impl/util/NumValCarrier.java
URL: http://svn.apache.org/viewvc/pig/trunk/src/org/apache/pig/impl/util/NumValCarrier.java?rev=1337400&r1=1337399&r2=1337400&view=diff
==============================================================================
--- pig/trunk/src/org/apache/pig/impl/util/NumValCarrier.java (original)
+++ pig/trunk/src/org/apache/pig/impl/util/NumValCarrier.java Fri May 11 22:27:07 2012
@@ -40,6 +40,7 @@ public class NumValCarrier {
byteToStr.put(DataType.FLOAT,valCarrier);
byteToStr.put(DataType.INTEGER,valCarrier);
byteToStr.put(DataType.LONG,valCarrier);
+ byteToStr.put(DataType.BOOLEAN,valCarrier);
byteToStr.put(DataType.MAP,mapCarrier);
byteToStr.put(DataType.TUPLE,tupleCarrier);
byteToStr.put(DataType.NULL,nullCarrier);
Modified: pig/trunk/test/org/apache/pig/test/TestSchema.java
URL: http://svn.apache.org/viewvc/pig/trunk/test/org/apache/pig/test/TestSchema.java?rev=1337400&r1=1337399&r2=1337400&view=diff
==============================================================================
--- pig/trunk/test/org/apache/pig/test/TestSchema.java (original)
+++ pig/trunk/test/org/apache/pig/test/TestSchema.java Fri May 11 22:27:07 2012
@@ -883,7 +883,16 @@ public class TestSchema {
"a,b,t:tuple(x,b:bag{t:tuple(a,b,c,x:tuple(z:bag{r:tuple(z)}))},z)",
"a:bag{t:tuple(a:bag{t:tuple(a:bag{t:tuple(a:bag{t:tuple(a:bag{t:tuple(a:bag{t:tuple(a:int,b:float)})})})})})}",
"a:bag{}",
- "b:{null:(a:int)}"
+ "b:{null:(a:int)}",
+ "int,int,int,int,int,int,int,int,int,int",
+ "long,long,long,long,long,long,long,long,long,long",
+ "float,float,float,float,float,float,float,float,float,float",
+ "double,double,double,double,double,double,double,double,double,double",
+ "boolean,boolean,boolean,boolean,boolean,boolean,boolean,boolean,boolean,boolean",
+ "(),(),(),(),(),(),(),(),(),()",
+ "{},{},{},{},{},{},{},{},{},{}",
+ "map[],map[],map[],map[],map[],map[],map[],map[],map[],map[]",
+ "int,int,long,long,float,float,double,double,boolean,boolean,(int,long,float,double,boolean),{(int,long,float,double,boolean)},map[(int,long,float,double,boolean)]"
};
for (String schemaString : schemaStrings) {
Schema s1 = Utils.getSchemaFromString(schemaString);