You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@hudi.apache.org by "Raymond Xu (Jira)" <ji...@apache.org> on 2022/01/09 07:31:00 UTC

[jira] [Created] (HUDI-3198) Spark SQL create table should check partition fields

Raymond Xu created HUDI-3198:
--------------------------------

             Summary: Spark SQL create table should check partition fields
                 Key: HUDI-3198
                 URL: https://issues.apache.org/jira/browse/HUDI-3198
             Project: Apache Hudi
          Issue Type: Improvement
          Components: Spark Integration
            Reporter: Raymond Xu


{code:sql}
create table hudi_cow_pt_tbl (
  id bigint,
  name string,
  ts bigint,
  dt string,
  hh string
) using hudi
tblproperties (
  type = 'cow',
  primaryKey = 'id',
  preCombineField = 'ts'
 )
partitioned by (dt, hh)
location '/tmp/hudi/hudi_cow_pt_tbl';{code}
 

The following sql should throw exception about invalid partition `name` 
{code:sql}
create table hudi_cow_existing_tbl2 using hudi 
partitioned by (dt, name) 
location 'file:///tmp/hudi/hudi_cow_pt_tbl';
{code}



--
This message was sent by Atlassian Jira
(v8.20.1#820001)