oracle中UTL_RAW.CAST_TO_RAW函数

项目中遇到要给blod字段初始化问题,是从另外一张表中组合数据

 

如果用以下代码将可以

update key_query t
   set t.content = utl_raw.cast_to_raw('123')

 如果想要在utl_raw.cast_to_raw()里使用select,记住要加括

update key_query
   set key_query.content = utl_raw.cast_to_raw((select k.describe
                                                 from knowledge_message k
                                                where k.mesg_id = '1'));

 

你可能感兴趣的:(blod)