Quantcast
Channel: Hortonworks » All Replies
Viewing all articles
Browse latest Browse all 3435

Not getting the desired output with a Hive query.

$
0
0

Hello All,

I have two input files which are ; delimited. I loaded these files into two tables. Both tables contain the information on books. I joined both the tables on ISBN field. Now I am trying the below query but I am not getting the desired output:-
SELECT a.BookRating, COUNT(BookTitle) FROM Books b JOIN Rating a on (b.ISBN = a.ISBN) WHERE b.YearOfPublication = 2002 GROUP BY a.BookRating;

I am not getting anything. It just shows OK on the terminal after the query runs completely. Please let me know what can be done. Thanks in advance.


Viewing all articles
Browse latest Browse all 3435

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>