[ 
https://issues.apache.org/jira/browse/TRAFODION-3148?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

David Wayne Birdsall resolved TRAFODION-3148.
---------------------------------------------
       Resolution: Fixed
    Fix Version/s: 2.3

> 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
>             Fix For: 2.3
>
>
> 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)

Reply via email to