SQL to add column and comment in table in single command

后端 未结 4 1879
無奈伤痛
無奈伤痛 2021-02-11 13:09

I am using Oracle 11g for my web application. I want to add a column and a comment to an existing table. I can do that easily with the below commands

ALTER TABLE         


        
4条回答
  •  旧巷少年郎
    2021-02-11 13:30

    Query to add column with comment are :

    alter table table_name 
    add( "NISFLAG"    NUMBER(1,0) )
    
    comment on column "ELIXIR"."PRD_INFO_1"."NISPRODGSTAPPL" is 'comment here'
    
    commit;
    

提交回复
热议问题