trafodion-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From se...@apache.org
Subject [6/7] trafodion git commit: Changes to report the error -1571 and -1572 correctly.
Date Fri, 06 Apr 2018 16:07:36 GMT
Changes to report the error -1571 and -1572 correctly.


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

Branch: refs/heads/master
Commit: c9b09aab38970fd4875ac940ec6624f74ebe9d37
Parents: 3b54b36
Author: selvaganesang <selva.govindarajan@esgyn.com>
Authored: Fri Apr 6 06:32:30 2018 +0000
Committer: selvaganesang <selva.govindarajan@esgyn.com>
Committed: Fri Apr 6 06:32:30 2018 +0000

----------------------------------------------------------------------
 core/sql/exp/exp_function.cpp | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/trafodion/blob/c9b09aab/core/sql/exp/exp_function.cpp
----------------------------------------------------------------------
diff --git a/core/sql/exp/exp_function.cpp b/core/sql/exp/exp_function.cpp
index 75ffcf9..9a1e332 100644
--- a/core/sql/exp/exp_function.cpp
+++ b/core/sql/exp/exp_function.cpp
@@ -2238,21 +2238,21 @@ Lng32 ex_function_position::errorChecks(Lng32 startPos, Lng32 occurrence,
   // startPos is 1 based. Cannot be <= 0
   if (startPos < 0)
     {
-      ExRaiseSqlError(heap, diagsArea, (ExeErrorCode)1572);
+      ExRaiseSqlError(heap, diagsArea, -1572);
       *(*diagsArea) << DgString0("START POSITION") << DgString1("INSTR function");

       return -1;
     }
   
   if (startPos == 0)
     {
-      ExRaiseSqlError(heap, diagsArea, (ExeErrorCode)1571);
+      ExRaiseSqlError(heap, diagsArea, -1571);
       *(*diagsArea) << DgString0("START POSITION") << DgString1("INSTR function");

       return -1;
     }
   
   if (occurrence < 0)
     {
-      ExRaiseSqlError(heap, diagsArea, (ExeErrorCode)1572);
+      ExRaiseSqlError(heap, diagsArea, -1572);
       *(*diagsArea) << DgString0("OCCURRENCE") << DgString1("INSTR function");

 
       return -1;
@@ -2260,7 +2260,7 @@ Lng32 ex_function_position::errorChecks(Lng32 startPos, Lng32 occurrence,
   
   if (occurrence == 0)
     {
-      ExRaiseSqlError(heap, diagsArea, (ExeErrorCode)1571);
+      ExRaiseSqlError(heap, diagsArea, -1571);
       *(*diagsArea) << DgString0("OCCURRENCE") << DgString1("INSTR function");

 
       return -1;


Mime
View raw message