I want to add the comment on each column in Hive Parquet table. I am trying to add comment as below:
create external table parquet_db.bdv_table
(
registration_dttm timestamp comment 'Registration date',
id int comment 'id_for_person',
name string comment 'user_name',
email string comment 'email address'
)
ROW FORMAT SERDE 'parquet.hive.serde.ParquetHiveSerDe'
STORED AS parquet
Location '/user/****/***';
But comments are not appearing on, however DDL gets created and data is also loading. Please let me know, how to add the comments in Hive Parquet table for each column.
You can drop the SERDE
specification from the create table
statement. Just using STORED AS PARQUET
will default to using org.apache.hadoop.hive.ql.io.parquet.serde.ParquetHiveSerDe
.
After creating table, desc parquet_db.bdv_table
should show the comment in output.