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 in Big Data Hadoop by Husa
35 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 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
691 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,720 points
48 views
0 votes
1 answer

Are some Pig real time use cases available?

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

answered Apr 20, 2018 in Big Data Hadoop by kurt_cobain
• 9,240 points
18 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
192 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
173 views
0 votes
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,510 points
2,392 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,510 points
244 views
0 votes
10 answers

hadoop fs -put command?

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

answered Dec 7, 2018 in Big Data Hadoop by Aditya
12,185 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,290 points
32 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,580 points
62 views