hive的建表语句

hive建表语句

CREATE TABLE ccwn_zh_event_push (
                                    customerid string,
                                    cardnumber string,
                                    accountnumber string,
                                    eventcode string,
                                    eventtime string,activities string,
                                    activityRefuseCode string,
                                    lables string)
    PARTITIONED BY(dt string)
    ROW FORMAT SERDE 'org.apache.hadoop.hive.ql.io.parquet.serde.ParquetHiveSerDe'
    WITH SERDEPROPERTIES ('fielddelim'='|','serialization.format'='|')
    STORED AS INPUTFORMAT 'org.apache.hadoop.hive.ql.io.parquet.MapredParquetInputFormat'
    OUTPUTFORMAT 'org.apache.hadoop.hive.ql.io.parquet.MapredParquetOutputFormat'
    LOCATION 'hdfs://hadoop102:8020/spdbccc/ccwn_zh_event_push';

show tables ;

hive的建表语句_第1张图片

建表之后load数据

load data local inpath '/opt/module/flink14/job/1.txt'  into table ccwn_zh_event_push ;

报错

Failed with exception java.io.IOE hdfs://nameservicel/event.txt is exception:java.lang.RuntimeException:ot a Parquet file

你可能感兴趣的:(hive)