I want a XML file format as below.
XML should look like below:-
<server name="Server123">
<schema name="cwmm">
<table name="ACC" rows="1000000"/>
<table name="KEYS" rows="1000000"/>
</schema>
<schema name="CWM1610">
<table name="ACC" rows="1000000"/>
<table name="KEYS" rows="1000000"/>
</schema>
what, I have done is created a temporary table called TAB_INFO with the information about the table_owner, tables and their rows. so please help in achieving the above format. I was thinking to use the package dbms_xmlgen but I am clueless how to achieve the above.
Table has columns as below:-
owner
table_name
num_rows
Thank you for the help.