No folder scanned yet.
Questions to ask it
Open reports-metadata.sqlite in any SQL browser, or run
reports-metadata.sql into Oracle. These run as they stand —
change the name in quotes to the one you are looking for.
Which reports read a table
A query keeps its SQL, so the question is asked of the text rather
than guessed from a name.
select f.file_name, q.select_text
from report_queries q
join report_files f on f.report_file_pk = q.report_file_fk
where upper(q.select_text) like '%CONTRACT%'
order by 1;
Numeric fields with a format mask
How a number is rendered, and in what font — the two things a
migration has to reproduce. A field has no data type of its own:
it draws a source, and the type belongs to that. The
view report_field_sources resolves the source, so
filtering to numbers is a column rather than a guess from the
mask. Join back to report_fields for the layout.
select f.file_name, v.report_field_name, v.source, v.format_mask,
d.font_face, d.font_size
from report_field_sources v
join report_fields d on d.report_field_pk = v.report_field_pk
join report_files f on f.report_file_pk = v.report_file_fk
where v.format_mask is not null
and v.datatype = 'number'
order by 1, 2;
A source can be a query column, a summary, a formula, a
placeholder or a parameter, and source_kind says
which. Drop the datatype line to see every masked
field; swap it for 'date' for the dates.
The data model: groups and their columns
What a report selects, with the type and width each column was
given.
select f.file_name, c.report_group_name, c.report_column_name,
c.datatype, c.desc_width as width, c.desc_expression
from report_columns c
join report_files f on f.report_file_pk = c.report_file_fk
where f.file_name like '%AMENDMENT%'
order by 2, 3;
Every label, and how it is drawn
Boilerplate text is a run inside a text object, so the words and
the font are one row.
select f.file_name, t.string_text, t.font_face, t.font_size
from report_text_segments t
join report_files f on f.report_file_pk = t.report_file_fk
where t.string_text is not null
order by 1;
Reports with PL/SQL in them
Formulas and program units carry their source, so a conversion can
be sized before it is started.
select f.file_name, u.report_program_unit_name, length(u.source_text) chars
from report_program_units u
join report_files f on f.report_file_pk = u.report_file_fk
where u.source_text is not null
order by 3 desc;