Not able to run Hive queries

0 votes

I am trying to execute some Hive commands. I try to run this command in Hive terminal:

bin/hive -e 'LOAD DATA INPATH 'kv1.txt' OVERWRITE INTO TABLE pokes;'

I get the following output:

Hive history file=/tmp/Bhavesh.Shah/hive_job_log_Bhavesh.Shah_201111301549_1377455380.txt
FAILED: Parse Error: line 1:17 mismatched input 'kv1' expecting StringLiteral near 'INPATH' in load statement

Can someone tell me how to execute the query?

Aug 30, 2018 in Big Data Hadoop by Neha
• 6,300 points
1,394 views

2 answers to this question.

0 votes

Try

bin/hive -e 'LOAD DATA INPATH kv1.txt OVERWRITE INTO TABLE pokes;'
answered Aug 30, 2018 by Frankie
• 9,830 points
0 votes

If you are loading your data from hdfs you should create a directory in hdfs and then load your data with its full path in hdfs. This would solve your problem.

answered Mar 3, 2020 by chima

edited Mar 4, 2020 by Gitika

Related Questions In Big Data Hadoop

0 votes
1 answer

Not able to run mapreduce job. Attempt failes error

The most common reason for this is ...READ MORE

answered Nov 22, 2018 in Big Data Hadoop by Omkar
• 69,210 points
964 views
0 votes
1 answer

Not able to create Hive table from HDFS file

You dont have to specify the file name ...READ MORE

answered Dec 5, 2018 in Big Data Hadoop by Omkar
• 69,210 points
2,290 views
0 votes
1 answer

Not able to insert data into hive table

Seems like a hive version problem.​ insert operation is ...READ MORE

answered Dec 14, 2018 in Big Data Hadoop by Omkar
• 69,210 points
2,641 views
0 votes
1 answer

Not able to insert in hive partition table

You have to add the partition before ...READ MORE

answered Dec 14, 2018 in Big Data Hadoop by Omkar
• 69,210 points
2,944 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
• 11,380 points
10,602 views
+2 votes
11 answers

hadoop fs -put command?

Hi, You can create one directory in HDFS ...READ MORE

answered Mar 16, 2018 in Big Data Hadoop by nitinrawat895
• 11,380 points
104,778 views
–1 vote
1 answer

Hadoop dfs -ls command?

In your case there is no difference ...READ MORE

answered Mar 16, 2018 in Big Data Hadoop by kurt_cobain
• 9,390 points
4,286 views
0 votes
1 answer
0 votes
1 answer
0 votes
1 answer

How to write examples to test whether the installation is validated or not?

You have some example jars in your ...READ MORE

answered Sep 5, 2018 in Big Data Hadoop by Frankie
• 9,830 points
494 views
webinar REGISTER FOR FREE WEBINAR X
REGISTER NOW
webinar_success Thank you for registering Join Edureka Meetup community for 100+ Free Webinars each month JOIN MEETUP GROUP