please change the Beautifier output for nested queries

Carlo Sirna

Member²
Hi,
If I try to beautify nested queries like this toy example:

SQL:
select * from (select * from (
select * from (select * from (
select * from (select * from dual) a) b ) c) d) e

I get this:

SQL:
select *
  from (select *
          from (select *
                  from (select * from (select * from (select * from dual) a) b) c) d) e

Style that I find less than useful because, maybe it looks good, but doesn't solve at all the problem of the original code: it is still impossible to easily see which subquery each of the a,b,c,d,e aliases refers to or which closing parenthesis matches a given open parenthesis.

Try to use plsql/beautifier on queries bigger than 2000/3000 rows (don't ask...) and you still will have to spend half an hour to re-beautify the code to really understand what it does.

Could you please rethink the beautifying algorithm for queries (or at least make it configurable, since for queries there is no configuration parameter at all) in order to produce something like this?:

SQL:
select *
from
(
  select *
  from
  (
    select *
    from
    (
      select *
      from
      (
        select *
        from
        (
          select * from dual
        ) a
      ) b
    ) c
  ) d
) e

Thank you!

 
Back
Top