How about using the explicit cast like
  ordered = ORDER query BY (int)z;

Alcaid

From:  "Patcharee Thongtra";<[EMAIL PROTECTED]>;
Date:  Fri, May 30, 2014 06:02 PM
To:  "user"<[EMAIL PROTECTED]>;

Subject:  java.lang.String cannot be cast to java.lang.Integer

Hi,

I got very strange exception.

80693 [main] ERROR org.apache.pig.tools.grunt.Grunt  - ERROR 1066:
Unable to open iterator for alias ordered. Backend error :
java.lang.String cannot be cast to java.lang.Integer
14/05/30 11:53:22 ERROR grunt.Grunt: ERROR 1066: Unable to open iterator
for alias ordered. Backend error : java.lang.String cannot be cast to
java.lang.Integer
In my pig script below, z is integer but pig complains as it is String.

query = load 'fino32' USING org.apache.hcatalog.pig.HCatLoader() as (
date: chararray,
u: float,
v: float,
t: float,
zone: int,
z: int);

ordered = ORDER query BY z;

dump ordered;
Any suggestion is appreciated.

Patcharee
NEW: Monitor These Apps!
elasticsearch, apache solr, apache hbase, hadoop, redis, casssandra, amazon cloudwatch, mysql, memcached, apache kafka, apache zookeeper, apache storm, ubuntu, centOS, red hat, debian, puppet labs, java, senseiDB