In most cases, each plan's line is put in a record of PLG$PROF_RECORD_SOURCES.
But that is not always true.
For example:
SQL> select first 1 * from rdb$database order by 1;
Select Expression
-> First N Records
-> Refetch
-> Sort (record length: 36, key length: 12)
-> Table "RDB$DATABASE" Full Scan
Here Refetch and Sort is put in the same record, with makes it difficult to reconstruct indentation.
Adding a LEVEL column to this table and views makes it easy to do it.
In most cases, each plan's line is put in a record of
PLG$PROF_RECORD_SOURCES.But that is not always true.
For example:
Here
RefetchandSortis put in the same record, with makes it difficult to reconstruct indentation.Adding a
LEVELcolumn to this table and views makes it easy to do it.