[
https://issues.apache.org/jira/browse/TRAFODION-3148?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16547064#comment-16547064
]
ASF GitHub Bot commented on TRAFODION-3148:
-------------------------------------------
Github user asfgit closed the pull request at:
https://github.com/apache/trafodion/pull/1649
> Creating a persistent sample table on a Hive table fails with some columns
> --------------------------------------------------------------------------
>
> Key: TRAFODION-3148
> URL: https://issues.apache.org/jira/browse/TRAFODION-3148
> Project: Apache Trafodion
> Issue Type: Bug
> Components: sql-cmp
> Affects Versions: 2.3
> Reporter: David Wayne Birdsall
> Assignee: David Wayne Birdsall
> Priority: Major
>
> The following reproduces the problem.
> First, create and populate a Hive table that uses the column name
> "__DIVISION_1__". (In Hive, one uses backticks to define delimited column
> names rather than double quotes as in standard SQL.):
> {{hive> create table dave2( a int, `__DIVISION_1__` int)}}
> > stored as textfile
> > ;
> {{OK}}
> {{Time taken: 0.122 seconds}}
> {{hive> insert into dave2 values (1,2),(3,4),(5,6),(7,8);}}
> Then, in Trafodion sqlci, attempt to create a random sample. This will fail:
> {{>>update statistics for table hive.hive.dave2 create sample random 90
> percent;}}
> {{*** ERROR[9200] UPDATE STATISTICS for table HIVE.HIVE.DAVE2 encountered an
> error (4023) from statement Process_Query.}}
> {{*** ERROR[4023] The degree of each row value constructor (1) must equal the
> degree of the target table column list (2).}}
> {{*** ERROR[8822] The statement was not prepared.}}{{--- SQL operation failed
> with errors.}}
> {{>>}}
> The probable cause of the problem is that "__DIVISION_1__" is assumed in
> Trafodion to be a derived column, but this assumption is incorrect for Hive
> tables.
>
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)