You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@trafodion.apache.org by db...@apache.org on 2017/10/05 15:25:11 UTC
[2/5] incubator-trafodion git commit: Fix bug noticed on pull request
review
Fix bug noticed on pull request review
Project: http://git-wip-us.apache.org/repos/asf/incubator-trafodion/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-trafodion/commit/6355b690
Tree: http://git-wip-us.apache.org/repos/asf/incubator-trafodion/tree/6355b690
Diff: http://git-wip-us.apache.org/repos/asf/incubator-trafodion/diff/6355b690
Branch: refs/heads/master
Commit: 6355b6909de9690020794b53ede7410a769dfd77
Parents: c22b6d1
Author: Dave Birdsall <db...@apache.org>
Authored: Tue Oct 3 17:05:22 2017 +0000
Committer: Dave Birdsall <db...@apache.org>
Committed: Tue Oct 3 17:05:22 2017 +0000
----------------------------------------------------------------------
core/sql/generator/GenRelUpdate.cpp | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/incubator-trafodion/blob/6355b690/core/sql/generator/GenRelUpdate.cpp
----------------------------------------------------------------------
diff --git a/core/sql/generator/GenRelUpdate.cpp b/core/sql/generator/GenRelUpdate.cpp
index 9b9b4e7..acfe7f9 100644
--- a/core/sql/generator/GenRelUpdate.cpp
+++ b/core/sql/generator/GenRelUpdate.cpp
@@ -315,12 +315,12 @@ static short genUpdConstraintExpr(Generator * generator,
{
NAColumn * sourceCol = ((IndexColumn*)sourceValId.getItemExpr())->getNAColumn();
ValueId targetValId;
- NAColumn *targetCol = NULL;
NABoolean found = FALSE;
for (CollIndex ni = 0; (!found) && (ni < targetRecExprArray.entries()); ni++)
{
const ItemExpr *assignExpr = targetRecExprArray[ni].getItemExpr();
- targetValId = assignExpr->child(0)->castToItemExpr()->getValueId();
+ targetValId = assignExpr->child(0)->castToItemExpr()->getValueId();
+ NAColumn *targetCol = NULL;
if (targetValId.getItemExpr()->getOperatorType() == ITM_BASECOLUMN)
targetCol = ((BaseColumn*)targetValId.getItemExpr())->getNAColumn();
else if (targetValId.getItemExpr()->getOperatorType() == ITM_INDEXCOLUMN)