调用存储过程:
select F_IF_ACCNUM_VALID('02045675027') as isValid from dual
-- 转MD5
update t_sys_user t set t.pic_path = (select md5(concat( md5(substr(t.pic_path,1,18)), 'bride')) from dual)
where length(PIC_PATH)=22
-- 拼头
update t_sys_user t set t.pic_path = (select concat('expertImage/',t.pic_path) from dual)
where user_name in (select user_name from t_sys_pic_path_backup)
-- 拼尾
update t_sys_user t set t.pic_path = (select concat(t.pic_path,'.png') from dual)
where user_name in (select user_name from t_sys_pic_path_backup)
-- 恢复
update t_sys_user t set t.pic_path = (select old_pic_path from t_sys_pic_path_backup)
where user_name in (select user_name from t_sys_pic_path_backup)
--获取uuid
SELECT rawtohex(sys_guid()) from dual;
建表添加注释
comment on column t_expert_sampling.order_id is '抽检单编号'
-- between
SELECT *
FROM T_ORDER O
WHERE O.CREATEDATETIME BETWEEN
TO_DATE('2016-10-08 12:30', 'yyyy-mm-dd hh24:mi') AND
TO_DATE('2016-10-14 13:00', 'yyyy-mm-dd hh24:mi')
AND TO_CHAR(O.CREATEDATETIME, 'hh24:mi:ss') BETWEEN '12:30:00' AND
'13:00:00'