[
https://issues.apache.org/jira/browse/HIVE-21160?focusedWorklogId=778918&page=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-778918
]
ASF GitHub Bot logged work on HIVE-21160:
-----------------------------------------
Author: ASF GitHub Bot
Created on: 07/Jun/22 08:06
Start Date: 07/Jun/22 08:06
Worklog Time Spent: 10m
Work Description: kasakrisz commented on code in PR #2855:
URL: https://github.com/apache/hive/pull/2855#discussion_r890894844
##########
ql/src/test/results/clientpositive/llap/check_constraint.q.out:
##########
@@ -2061,65 +2061,87 @@ PREHOOK: query: explain cbo update acid_uami_n0 set de
= 893.14 where de = 103.0
PREHOOK: type: QUERY
PREHOOK: Input: default@acid_uami_n0
PREHOOK: Output: default@acid_uami_n0
+PREHOOK: Output: default@acid_uami_n0
POSTHOOK: query: explain cbo update acid_uami_n0 set de = 893.14 where de =
103.00 or de = 119.00
POSTHOOK: type: QUERY
POSTHOOK: Input: default@acid_uami_n0
POSTHOOK: Output: default@acid_uami_n0
+POSTHOOK: Output: default@acid_uami_n0
CBO PLAN:
-HiveSortExchange(distribution=[any], collation=[[0]])
- HiveProject(row__id=[$5], i=[$0], _o__c2=[893.14:DECIMAL(5, 2)], vc=[$2])
- HiveFilter(condition=[AND(IN($1, 103:DECIMAL(3, 0), 119:DECIMAL(3, 0)),
enforce_constraint(IS NOT FALSE(>=(893.14, CAST($0):DECIMAL(5, 2)))))])
Review Comment:
The original update statement is rewritten to multi insert statement and
constraint check is not supported in CBO when inserting. It is done by physical
plan.
Issue Time Tracking
-------------------
Worklog Id: (was: 778918)
Time Spent: 5h (was: 4h 50m)
> Rewrite Update statement as Multi-insert and do Update split early
> ------------------------------------------------------------------
>
> Key: HIVE-21160
> URL: https://issues.apache.org/jira/browse/HIVE-21160
> Project: Hive
> Issue Type: Sub-task
> Components: Transactions
> Affects Versions: 3.0.0
> Reporter: Eugene Koifman
> Assignee: Krisztian Kasa
> Priority: Major
> Labels: pull-request-available
> Time Spent: 5h
> Remaining Estimate: 0h
>
--
This message was sent by Atlassian Jira
(v8.20.7#820007)