Skip to content

Instantly share code, notes, and snippets.

Avatar

Sundarraj_Mainframe_BigData_Developer Sundar1906

  • SopraSteria
  • Chennai
View GitHub Profile
@Sundar1906
Sundar1906 / WordCount.hive
Created May 19, 2018
WordCount in Hive Query
View WordCount.hive
CREATE TABLE Wcount(words STRING);
LOAD DATA LOCAL INPATH '/home/skumares/InputData.txt' OVERWRITE INTO TABLE Wcount;
Select wc,count(*) from(Select explode(split(words,' ')) from Wcount) p group by wc;