Pig: mismatched input "T1" expecting RIGHT_CURLY

0 votes
{(3,8,9) (1,2,3)}
{(1,4,7) (1,2,3)}
{(2,5,8) (1,2,3)}

A =LOAD "bag.txt" USING PigStorage(" ") AS (B:BAG{T:tuple(t1,t2,t3) T1:tuple(t1,t2,t3)});

for the above set I am getting the error 

ERROR 1200: mismatched input "T1" expecting RIGHT_CURLY
Details at logfile: /mnt/home/edureka_418649/pig_1544546095890.log
Feb 13, 2019 in Big Data Hadoop by Husa
148 views

1 answer to this question.

0 votes

In Pig, the bag and tuple format should be correct otherwise the data will not be loaded correctly in the Pig alias. Please refer to the below screenshot for the bag and tuple format:

image

Now, please load the data using the below Pig query.

image

The output will be as below:

image

answered Feb 13, 2019 by Yuri

Related Questions In Big Data Hadoop

+1 vote
2 answers

Execute Pig Script from Grunt Shell

From your current directory run  pig -x local Then ...READ MORE

answered Oct 25, 2018 in Big Data Hadoop by Kunal
1,682 views
0 votes
1 answer

How can I get the respective Bitcoin value for an input in USD when using c#

Simply make call to server and parse ...READ MORE

answered Mar 25, 2018 in Big Data Hadoop by charlie_brown
• 7,770 points
166 views
0 votes
1 answer

Are some Pig real time use cases available?

You can refer to this website https://acadgild.com/blog/pig-u ...READ MORE

answered Apr 20, 2018 in Big Data Hadoop by kurt_cobain
• 9,310 points
118 views
0 votes
1 answer

Why Apache Pig is used instead of Hadoop?

As you know writing mapreduce programs in ...READ MORE

answered May 7, 2018 in Big Data Hadoop by Ashish
• 2,630 points
588 views
0 votes
1 answer

What do we exactly mean by “Hadoop” – the definition of Hadoop?

The official definition of Apache Hadoop given ...READ MORE

answered Mar 16, 2018 in Big Data Hadoop by Shubham
598 views
+1 vote
1 answer

Hadoop Mapreduce word count Program

Firstly you need to understand the concept ...READ MORE

answered Mar 16, 2018 in Data Analytics by nitinrawat895
• 10,920 points
5,314 views
0 votes
1 answer

hadoop.mapred vs hadoop.mapreduce?

org.apache.hadoop.mapred is the Old API  org.apache.hadoop.mapreduce is the ...READ MORE

answered Mar 16, 2018 in Data Analytics by nitinrawat895
• 10,920 points
781 views
+1 vote
11 answers

hadoop fs -put command?

put syntax: put <localSrc> <dest> copy syntax: copyF ...READ MORE

answered Dec 7, 2018 in Big Data Hadoop by Aditya
32,413 views
0 votes
1 answer

Getting error in Custom Input Format

Use this property directly to delimit the ...READ MORE

answered Apr 19, 2018 in Big Data Hadoop by Shubham
• 13,380 points
76 views
0 votes
1 answer

Use of MapReduce in PIG

Apache Pig programs are written in a ...READ MORE

answered Jul 25, 2018 in Big Data Hadoop by shams
• 3,600 points
324 views