Error : ORA-01704: string literal too long

后端 未结 4 973
梦毁少年i
梦毁少年i 2020-11-29 06:58

While I try to set the value of over 4000 characters on a field that has data type CLOB, it gives me this error :

ORA-01704: string lite

4条回答
  •  佛祖请我去吃肉
    2020-11-29 07:49

    Try to split the characters into multiple chunks like the query below and try:

    Insert into table (clob_column) values ( to_clob( 'chunk 1' ) || to_clob( 'chunk 2' ) );
    

    It worked for me.

提交回复
热议问题