I want to filter the records of data set A whose flight_delay_time is less than some specific values(x).
But I will get the value of x from another pig query which is a tuple in the sense x is a tuple.
But using the following statement is throwing an error:
B = FILTER A by flight_delay_time < x; dump B;
The data in file A is in the following way;
ravi,savings,avinash,2,char,33,F,22,44,12,13,33,44,22,11,10,22,26 avinash,current,sandeep,3,char,44,M,33,11,10,12,33,22,39,12,23,19,35 supreeth,savings,prabhash,4,char,55,F,22,12,23,12,44,56,7,88,34,23,68 lavi,current,nirmesh,5,char,33,M,11,10,33,34,56,78,54,23,445,66,77 Venkat,savings,bunny,6,char,11,F,99,12,34,55,33,23,45,66,23,23,28
the value of x = (40) which is stored as a tuple.
the last column in the above data denotes the flight_delay_time.
I am extracting the value of X in the following way.
following is the data stored in C_CONTROL_BATCH.txt
25 35 40 15
I used following code to extract the value of X.
control_batch = LOAD 'C_CONTROL_BATCH.txt' AS (start:int); variable = ORDER control_batch BY start DESC; X = LIMIT starttime 1;