建外表实例

CREATE EXTERNAL TABLE `ods_opay_user_order_hi_test`(
`__db` string COMMENT 'from deserializer',
`__server_id` string COMMENT 'from deserializer',
`__file` string COMMENT 'from deserializer',
`__pos` string COMMENT 'from deserializer',
`__row` string COMMENT 'from deserializer',
`__table` string COMMENT 'from deserializer',
`__deleted` string COMMENT 'from deserializer',
`__version` string COMMENT 'from deserializer',
`__connector` string COMMENT 'from deserializer',
`__ts_ms` bigint COMMENT 'from deserializer',
`uuid` string COMMENT 'from deserializer',
`id` bigint COMMENT 'from deserializer',
`order_no` string COMMENT 'from deserializer',
`order_user_type` string COMMENT 'from deserializer',
`user_id` string COMMENT 'from deserializer',
`amount` bigint COMMENT 'from deserializer',
`country` string COMMENT 'from deserializer',
`currency` string COMMENT 'from deserializer',
`flow_type` string COMMENT 'from deserializer',
`fee_amount` bigint COMMENT 'from deserializer',
`fee_pattern` string COMMENT 'from deserializer',
`order_status` string COMMENT 'from deserializer',
`merchant_id` string COMMENT 'from deserializer',
`service_type` string COMMENT 'from deserializer',
`pay_channel` string COMMENT 'from deserializer',
`business_type` string COMMENT 'from deserializer',
`other_trader` string COMMENT 'from deserializer',
`after_balance` string COMMENT 'from deserializer',
`create_time` bigint COMMENT 'from deserializer',
`update_time` bigint COMMENT 'from deserializer')
PARTITIONED BY (
`dt` string,
`hour` string)
ROW FORMAT SERDE
'org.openx.data.jsonserde.JsonSerDe'
WITH SERDEPROPERTIES (
'ignore.malformed.json'='true')
STORED AS INPUTFORMAT
'org.apache.hadoop.mapred.TextInputFormat'
OUTPUTFORMAT
'org.apache.hadoop.hive.ql.io.HiveIgnoreKeyTextOutputFormat'
LOCATION
'oss://opay-datalake/opay_binlog_test/opay_bigorder.opay_bigorder.user_order_all';

上一篇:在Javascript中将BigInteger转换为Int64


下一篇:[题解](排列组合)luogu_P3223排队