Before using this function, you must create a LOB column to receive the converted LONG values. To convert LONG values, create a CLOB column. To convert LONG RAW values, create a BLOB column.
You cannot use the TO_LOB function to convert a LONG column to a LOB column in the subquery of a CREATE TABLE ... AS SELECT statement if you are creating an index-organized table. Instead, create the index-organized table without the LONG column, and then use the TO_LOB function in an INSERT ... AS SELECT statement.
比如:
table_long是以前的表
create table table_lob as select xxx,xxx,xxx,to_lob(以前的long字段) from table_long
1 个回复
老头子 - 专注是唯一的捷径 2016-07-08 回答
赞同来自: BAO胖子
使用CTAS创建一个表和以前表一样,但是对应的LONG改成LOB
比如:
table_long是以前的表
create table table_lob as select xxx,xxx,xxx,to_lob(以前的long字段) from table_long