Beautifier Question

t21931

Member
I've just downloaded an eval copy of PL/SQL Dev 6.

Is there a way to section-off a piece of PL/SQL code so that the beautifier does NOT update it?

Thanks.
 
Thanks. That does work, but it would be nice to wrap a piece of code in some special text that would tell to the beautifier to ignore it, especially if you have tons of code to work through.

Thanks again for your help.
 
For example, I use the WITH clause in some of my cursors, which the Beautifier can't handle. Of course, neither can Quest Software's FormatterPlus.

It gets kind of cumbersome commenting the offending part out, running the Beautifier and then restoring the cursors.

But it could be worse! :-)
 
Sometimes you can trick the beautifier into formating the way you want with comments.
eg I was getting:
update x.y
set (c01, c02, , c40) = (select s01,
s02,
,
s40
);
(ie forty columns selected and updated)
which wasn't real easy to read when the select statement ended up at about column 650 in the editer. I used double dash comments to force beautifier to keep code on separate lines and ended up with the following:
update x.y
set (c01, --
c02, --
, --
c40) --
= (select s01,
s02,
,
s40
);
which at least keeps all the text on the screen.
Still I would like the idea of a specific commented string that Beautifier would recognise to ignore sections of code :-)
 
Whoops, lost the leading spaces formatting in my reply, should have previewed it :-(
Hope this example shows what I mean:
Code:
update x.y
   set (c01, c02, <...>, c40) = (select s01,
                                        s02,
                                        <...>,
                                        s40
                                   from <etc>);
Changed to:
Code:
update x.y
   set (c01,  --
       c02,   --
       <...>, --
       c40)   --
       = (select s01,
                 s02,
                 <...>,
                 s40
            from <etc>);
:-)
 
Back
Top