sql - updating data based on on column is null or not null -


i updating table on column based on whether column empty or null. if null take direct data .if not null means take existing current data + new data.i doing using decode working fine. column datatype when 'clob' not working. alternative achieve this.

for ex id data

  11   ab   15   null 

now if want upate data id 11 should old data + new data ie ab:cd : seperate new , old if want update data id 15 should new data ie= ef

 update testing   set data = decode( data ,null,'confirm',data||sysdate||'test' )    id=15; 

where data column checking .could 1 please guide how in clob data type.

use case statements. pseudo code

 update testing   set data = case when data null direct data                   else existing current data + new data              end   id=15; 

Comments