码迷,mamicode.com
首页 > 数据库 > 详细

oracle case where 复杂sql语句

时间:2015-08-04 12:58:26      阅读:104      评论:0      收藏:0      [点我收藏+]

标签:

         update hr_user u set u.is_approve=(case
         when u.curr_org_id in
              (select t.org_id
                 from hr_organization t
                start with t.org_id = 10001263
               connect by prior org_id = t.org_id_parent) then
          N
         ELSE
          Y
       END);
       
       
        update hr_user u set u.is_approve=(case
         when u.curr_org_id in
              (select t.org_id
                 from hr_organization t
                start with t.org_id = 10001263
               connect by prior org_id = t.org_id_parent) then
          N
         ELSE
          Y
       END) where u.EMP_NUM=066001;

oracle复杂sql语句   oracle动态交叉表,oracle存储过程分页

oracle case where 复杂sql语句

标签:

原文地址:http://www.cnblogs.com/xunianchong/p/4701384.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!