Github user DaveBirdsall commented on a diff in the pull request:

    https://github.com/apache/trafodion/pull/1543#discussion_r187139067
  
    --- Diff: core/sql/optimizer/RelExpr.cpp ---
    @@ -7880,11 +7880,17 @@ NABoolean 
GroupByAgg::tryToPullUpPredicatesInPreCodeGen(
           else
             pulledPredicates += tempPulledPreds;
     
    +      // just remove pulled up predicates from char. input
    +      ValueIdSet newInputs(getGroupAttr()->getCharacteristicInputs());
    +      myLocalExpr += selectionPred();
    +      myLocalExpr -= tempPulledPreds;
    +      myLocalExpr.weedOutUnreferenced(newInputs);
    --- End diff --
    
    Hi Andy. Thanks! I figured out why I could not reproduce the issue. (The 
issue is that the parameterized version of the query returns zero rows when it 
should return one.) There is another change which I recently merged, 
https://github.com/apache/trafodion/pull/1546, that either fixes this problem 
or masks it. I am not sure which yet. If I set CQD COMP_BOOL_158 'OFF', I can 
now reproduce the problem on the latest code. I'll spend some time playing with 
your code change today or tomorrow and evaluate it. Thanks.


---

Reply via email to