SQLDeveloper - 自定义重构 - >环绕着

时间:2015-01-29 15:22:45

标签: oracle-sqldeveloper

我经常需要在SQL中注释掉一行或一行。在大多数情况下,我的查询将被加载到另一个工具,如BIRT,它将查询转换为单行。因此,我不能只使用单行注释( - ),必须使用多行注释(/ * * /)。

有没有办法用块注释包围块?例如,我希望能够轻松转变:

select *
from foo, count(*)
where foo.bar = '1'
  and foo.baru != foo.bar
  and foo.barid in
    (select barid from bar where foo = 1)
group by foo
order by foo desc;

进入这个:

select *
from foo, count(*)
where foo.bar = '1'
  and foo.baru != foo.bar
  and foo.barid in
    (select barid from bar /*where foo = 1*/)
group by foo
order by foo desc;

Refactor --> Surround with in right click menu

谢谢!

0 个答案:

没有答案