You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@trafodion.apache.org by su...@apache.org on 2018/02/02 04:08:48 UTC

[1/2] trafodion git commit: fix TRAFODION-2930 [FIRST N] will cause sqlci core dump

Repository: trafodion
Updated Branches:
  refs/heads/master 3e149d2c3 -> e392ffc44


fix TRAFODION-2930 [FIRST N] will cause sqlci core dump


Project: http://git-wip-us.apache.org/repos/asf/trafodion/repo
Commit: http://git-wip-us.apache.org/repos/asf/trafodion/commit/28e0c559
Tree: http://git-wip-us.apache.org/repos/asf/trafodion/tree/28e0c559
Diff: http://git-wip-us.apache.org/repos/asf/trafodion/diff/28e0c559

Branch: refs/heads/master
Commit: 28e0c559180a0fca488047c29e993a21eef15a5a
Parents: 6d38e58
Author: kakaxi3019 <ju...@163.com>
Authored: Thu Feb 1 01:23:46 2018 +0000
Committer: kakaxi3019 <ju...@163.com>
Committed: Thu Feb 1 01:23:46 2018 +0000

----------------------------------------------------------------------
 core/sql/executor/ExFirstN.cpp | 9 ++++++++-
 1 file changed, 8 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/trafodion/blob/28e0c559/core/sql/executor/ExFirstN.cpp
----------------------------------------------------------------------
diff --git a/core/sql/executor/ExFirstN.cpp b/core/sql/executor/ExFirstN.cpp
index 0937eea..a8e562e 100644
--- a/core/sql/executor/ExFirstN.cpp
+++ b/core/sql/executor/ExFirstN.cpp
@@ -202,7 +202,14 @@ short ExFirstNTcb::work()
 	    // 0 means process all but don't return any rows.
 	    // -1 means get all rows. Should not reach this state.
 	    // <-1 means return the last '-(N+2)' rows.
-            effectiveFirstN_ = firstnTdb().firstNRows();
+            //TRAFODION-2930
+            //fix [first 600000000000] crash
+	    //effectiveFirstN_ = firstnTdb().firstNRows();
+            Int64 nFirstN = firstnTdb().firstNRows();
+            Int64 nMaxInt = INT_MAX;
+            effectiveFirstN_ = Lng32( min( nMaxInt,nFirstN ) );
+            //TRAFODION-2930
+
             returnedSoFar_ = 0;
 
             if (firstnTdb().firstNRowsExpr_)


[2/2] trafodion git commit: Merge [TRAFODION-2930] PR-1430 [FIRST N] will cause sqlci core dump

Posted by su...@apache.org.
Merge [TRAFODION-2930] PR-1430 [FIRST N] will cause sqlci core dump


Project: http://git-wip-us.apache.org/repos/asf/trafodion/repo
Commit: http://git-wip-us.apache.org/repos/asf/trafodion/commit/e392ffc4
Tree: http://git-wip-us.apache.org/repos/asf/trafodion/tree/e392ffc4
Diff: http://git-wip-us.apache.org/repos/asf/trafodion/diff/e392ffc4

Branch: refs/heads/master
Commit: e392ffc4432298e80d0ac92f252458895945ac1a
Parents: 3e149d2 28e0c55
Author: Suresh Subbiah <su...@apache.org>
Authored: Fri Feb 2 04:08:36 2018 +0000
Committer: Suresh Subbiah <su...@apache.org>
Committed: Fri Feb 2 04:08:36 2018 +0000

----------------------------------------------------------------------
 core/sql/executor/ExFirstN.cpp | 9 ++++++++-
 1 file changed, 8 insertions(+), 1 deletion(-)
----------------------------------------------------------------------