I am trying to create a partition table NYSE_TBL and i am partitioning it based on SYMBOLS and i used the below query
create table nyse3
(exchange_data string,
stock_date string,
stock_price_open double,
stock_prce_high double,
stock_prce_low double,
stock_prce_close double,
stock_volume double,
stock_price_adj_close double)
partitioned by (symbol string)
row format delimited
fields terminated by ',';
after creating the table when i tried to describe the schema of NYSE3 i am getting the below schema
describe nyse3;
OK
exchange_data string
stock_date string
stock_price_open double
stock_prce_high double
stock_prce_low double
stock_prce_close double
stock_volume double
stock_price_adj_close double
symbol string
# Partition Information
# col_name data_type comment
symbol string
Time taken: 0.081 seconds, Fetched: 14 row(s)
My question here is , Why the partition column (SYMBOL) is described in the table schema? Am i doing some thing wrong in creating the table?
This is the default behaviour of DESCRIBE TABLE
.
DESCRIBE
shows the list of columns that includes both non-partition columns and partition columns for the given table. In addition to this listing, the partition columns are again displayed separately under # Partition Information
to distinguish the partition columns from the non-partition columns.
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.