Aman Sinha has posted comments on this change. ( http://gerrit.cloudera.org:8080/17168 )
Change subject: IMPALA-10564: Return error when inserting an invalid decimal value ...................................................................... Patch Set 7: > Patch Set 7: > > When decimal_v2 is set as false, Impala return a warning and insert NULL. So > we don't need to introduce another query option. The bug is not related with > ABORT_ON_ERROR. Even ABORT_ON_ERROR is set false, we still should abort the > query with an error for overflowed decimal value. In first two cases, current > code abort the query with an error for invalid decimal value when > ABORT_ON_ERROR is set false. To fix the issue, we just return error in table > writer if we found got NULL for decimal columns as my patch set 2. Or fix it > more aggressively, by replacing "return Status:OK()" with "return > state->CheckQueryState())" in HdfsTableSink::Send() and KuduTableSink::Send(). Since decimal_v2 is the default, we only need to focus on that. Based on your 3 examples it is clear that we are already returning the Decimal overflow error in the common cases of 1 and 2. For the not common case 3, if you just ran the SELECT portion of the CTAS, it will also return the same error. So, it makes sense to return error for the CTAS as well. I agree that a new query option is not needed. For case 3, when running the CTAS, the log file does show 'UDF ERROR: Decimal expression overflowed' in the stack trace for HdfsTableSink::Send() but the execution continues and the row is inserted. Is this what you were referring to for the aggressive fix ? -- To view, visit http://gerrit.cloudera.org:8080/17168 To unsubscribe, visit http://gerrit.cloudera.org:8080/settings Gerrit-Project: Impala-ASF Gerrit-Branch: master Gerrit-MessageType: comment Gerrit-Change-Id: I64ce4ed194af81ef06401ffc1124e12f05b8da98 Gerrit-Change-Number: 17168 Gerrit-PatchSet: 7 Gerrit-Owner: Wenzhe Zhou <[email protected]> Gerrit-Reviewer: Aman Sinha <[email protected]> Gerrit-Reviewer: Impala Public Jenkins <[email protected]> Gerrit-Reviewer: Thomas Tauber-Marshall <[email protected]> Gerrit-Reviewer: Wenzhe Zhou <[email protected]> Gerrit-Comment-Date: Mon, 22 Mar 2021 17:57:22 +0000 Gerrit-HasComments: No
