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

    https://github.com/apache/incubator-trafodion/pull/826#discussion_r87315939
  
    --- Diff: core/sql/optimizer/RelSequence.cpp ---
    @@ -1179,20 +1179,21 @@ RelExpr *RelSequence::bindNode(BindWA *bindWA)
     
         sequencedColumns() += newColumn->getValueId();
       }
    -  
    +  ValueIdMap ncToOldMap;
       for(i = 0; i < colList->entries(); i++) 
       {
         ValueId columnValueId = colList->at(i)->getValueId();
         ItemExpr *newColumn = new (bindWA->wHeap()) 
           NotCovered (columnValueId.getItemExpr());
         newColumn->synthTypeAndValueId();
    +    newColumn->setOrigOpType(columnValueId.getItemExpr()->origOpType());
         
         resultTable->addColumn(bindWA,
           colList->at(i)->getColRefNameObj(),
           newColumn->getValueId(),
           USER_COLUMN,
           colList->at(i)->getHeading());
    -
    +    ncToOldMap.addMapEntry(columnValueId,newColumn->getValueId());
    --- End diff --
    
    These ValueIdMaps are usually oriented like the operators in the tree, with 
values that are up the tree on top and those that are lower in the tree on the 
bottom. In this case, the "not covered" are in the upper part of the tree and 
the regular columns are lower. So, that's how they should go into the map, to 
avoid confusion.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---

Reply via email to