How to load json file format data into hive table - for beginners

preview_player
Показать описание
In this tutorial we'll see how to load json file format data into hive tables.

So this video is all about “Loading data from JSON file format into HIVE tables”

First of all,
After the Jar is downloaded, copy the jar file to your Hive installation--lib folder
Then go to the linux shell and add the jar file
Make sure all the Hadoop daemons are running by running the jps query in Hadoop ( not in hive)
Create a table using the query below :
create table products_info_test(id STRING, name STRING, reseller STRING, category STRING,
price DOUBLE, discount INT, profit_percent INT) ROW FORMAT SERDE
Once the table is created, check the table columns : describe products_info_test;
The data is loaded successfully, now test it by going typing “select * from products_info-test;
Please provide your feedback if this is useful.
Рекомендации по теме
Комментарии
Автор

I am having a .dat File. I am unable to make out the number of columns and the column header in it. Can you please help me to load the file in hive?

sowrabharavishankar