> On May 9, 2017, 8:31 p.m., Jason Dere wrote: > > ql/src/java/org/apache/hadoop/hive/ql/optimizer/DynamicPartitionPruningOptimization.java > > Line 216 (original), 217 (patched) > > <https://reviews.apache.org/r/59080/diff/1/?file=1711192#file1711192line217> > > > > There should be a better way to determine which table the column comes > > from. > > This should also be done after confirming the join key is a column > > reference.
Working on alternate approach. > On May 9, 2017, 8:31 p.m., Jason Dere wrote: > > ql/src/java/org/apache/hadoop/hive/ql/optimizer/DynamicPartitionPruningOptimization.java > > Lines 226 (patched) > > <https://reviews.apache.org/r/59080/diff/1/?file=1711192#file1711192line228> > > > > This is automatically using the first TS in your list of candidates as > > the tableAlias - which is not necessarily the table the key column comes > > from. Ditto > On May 9, 2017, 8:31 p.m., Jason Dere wrote: > > ql/src/java/org/apache/hadoop/hive/ql/optimizer/DynamicPartitionPruningOptimization.java > > Line 463 (original), 490 (patched) > > <https://reviews.apache.org/r/59080/diff/1/?file=1711192#file1711192line508> > > > > Can you change this assert to Preconditions.checkNotNull() sure. Thanks > On May 9, 2017, 8:31 p.m., Jason Dere wrote: > > ql/src/java/org/apache/hadoop/hive/ql/parse/SemanticAnalyzer.java > > Line 9064 (original), 9058 (patched) > > <https://reviews.apache.org/r/59080/diff/1/?file=1711194#file1711194line9064> > > > > This whole parsing logic seems hard to follow .. I don't see the need > > for a loop to parse each hint argument. If the format is (alias, colName, > > number) in that order, can't you just parse each argument in order, if the > > args tree has enough children? > > > > One effect of changing this is you only have to insert the hints in one > > place in the code. I will try to simplify the code. - Deepak ----------------------------------------------------------- This is an automatically generated e-mail. To reply, visit: https://reviews.apache.org/r/59080/#review174364 ----------------------------------------------------------- On May 9, 2017, 7:32 a.m., Deepak Jaiswal wrote: > > ----------------------------------------------------------- > This is an automatically generated e-mail. To reply, visit: > https://reviews.apache.org/r/59080/ > ----------------------------------------------------------- > > (Updated May 9, 2017, 7:32 a.m.) > > > Review request for hive and Jason Dere. > > > Repository: hive-git > > > Description > ------- > > Semijoin Hint : Should able to handle more than 1 hint per alias. > - If a user provides a hint, only that semijoin optimization is performed. > - If there are more than 1 hints for an alias, it is upto user to make sure > the (alias + colName) combo is unique. > - Works with join aliases. > - Refactored the logic to generate semijoin to keep the inner loops count > down. > > > Diffs > ----- > > > ql/src/java/org/apache/hadoop/hive/ql/optimizer/DynamicPartitionPruningOptimization.java > f56b9cbb18 > ql/src/java/org/apache/hadoop/hive/ql/parse/ParseContext.java 6de4bcd64a > ql/src/java/org/apache/hadoop/hive/ql/parse/SemanticAnalyzer.java > 5115fc8090 > ql/src/java/org/apache/hadoop/hive/ql/parse/SemiJoinHint.java 1f24e23ff3 > ql/src/test/queries/clientpositive/semijoin_hint.q 5fbc273e7d > ql/src/test/results/clientpositive/llap/semijoin_hint.q.out 3ffc2352a4 > > > Diff: https://reviews.apache.org/r/59080/diff/1/ > > > Testing > ------- > > > Thanks, > > Deepak Jaiswal > >