Tuesday, October 21, 2014

executing sequence of JOIN, WHERE, GROUP BY HAVING clauses in Hive

Understanding the sequence of executing sequence of clauses in Hive is very helpful for optimizing query. It will be idea if we can make every inter steps to generate data set as small as possible. The order of executing part of a query:

  1. FROM & JOINs determine & filter rows
  2. WHERE more filters on the rows
  3. GROUP BY combines those rows into groups
  4. HAVING filters groups
  5. ORDER BY arranges the remaining rows/groups

No comments:

Post a Comment