1. 程式人生 > >vertica中增加表的中文表名和中文註釋

vertica中增加表的中文表名和中文註釋

1、增加表中文名稱sql

comment on table 使用者名稱.表名稱 is '表中文名稱';

例:

comment on table test.aaa  is 'aaa測試表';

2、增加表中文註釋
2.1、增加表中文註釋需要查出projections

select projection_name from PROJECTIONS where owner_name = '使用者名稱' and anchor_table_name = '表名稱' limit 1;

例:

 select projection_name from PROJECTIONS where owner_name = 'test' and anchor_table_name = 'aaa' limit 1;

查出:
aaa_b0
2.2、增加表中文欄位註釋

comment on column 使用者名稱.分割槽.欄位 is'欄位中文註釋';

例:

 comment on column test.aaa_b0.id is '序號';

3、最後

commit;