[ https://issues.apache.org/jira/browse/HIVE-13737?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15302296#comment-15302296 ]
frank luo commented on HIVE-13737: ---------------------------------- forgot to mention I was using TEZ on Hive. > incorrect count when multiple inserts with union all > ---------------------------------------------------- > > Key: HIVE-13737 > URL: https://issues.apache.org/jira/browse/HIVE-13737 > Project: Hive > Issue Type: Bug > Components: Hive > Affects Versions: 1.2.1 > Environment: hdp 2.3.4.7 on Red Hat 6 > Reporter: Frank Luo > Priority: Critical > > Here is a test case to illustrate the issue. It seems MR works fine but Tez > is having the problem. > CREATE TABLE test(col1 STRING); > CREATE TABLE src (col1 string); > insert into table src values ('a'); > INSERT into TABLE test > select * from ( > SELECT * from src > UNION ALL > SELECT * from src) x; > -- do it one more time > INSERT INTO TABLE test > SELECT * from src > UNION ALL > SELECT * from src; > --below gives correct result > SELECT * FROM TEST; > --count is incorrect. It might give either '1' or '2', but I am expecting '4' > SELECT count (*) FROM test; -- This message was sent by Atlassian JIRA (v6.3.4#6332)