About Me.

My self Adinarayana working as Implementation Application DBA with advanced technologies like RAC/PCP,OID/SSO,DMZ,Exadata and Fusion Middleware i.e Demantra,Application Server,SOA,FMW,BPEL and UPK. Created this blog to share the useful information related to DBA and Application DBA Your comments and suggestions are most welcome. Disclaimer: Please note all the views and opinions expressed in this site are my own. It's not recommend to use the fixes/suggestions provided in this site directly in production instance, please test them before implementing.

Tuesday, July 9, 2013

To Convert File in Xml Format

SQL>set head on feed on
SQL>spool <File name>.xls
SQL>set markup html on
SQL>@script.sql
SQL>set markup html off
SQL>spool off



Output in execl format
==========================

SET LINESIZE 4000
SET VERIFY OFF
SET FEEDBACK OFF
SET PAGESIZE 999
SET MARKUP HTML ON ENTMAP ON SPOOL ON PREFORMAT OFF
SPOOL Prod.xls
select NAME,VALUE from gv$parameter;
spool off;


SET LINESIZE 4000
SET VERIFY OFF
SET FEEDBACK OFF
SET PAGESIZE 999
SET MARKUP HTML ON ENTMAP ON SPOOL ON PREFORMAT OFF
SPOOL Prod.xls
select count(*) from aps_params order by 1;
spool off;

No comments:

Post a Comment