Oracle: Changing VARCHAR2 column to CLOB

前端 未结 3 1441
南笙
南笙 2021-02-01 02:33

I have an encountered an issue where the data I was trying to store in my varchar2(4000) column was too big, so I wish to change the column to one more suitable for storing larg

3条回答
  •  醉梦人生
    2021-02-01 02:52

    The VARCHAR2 column cannot be directly converted to CLOB but it can be done in 2 steps:

    • Convert column datatype from VARCHAR2 to LONG.
    • Convert column datatype from LONG to CLOB.
    ALTER TABLE table MODIFY column long;
    ALTER TABLE table MODIFY column clob;
    

提交回复
热议问题