20.6 Using a Distribution XML File at Runtime

The method for using a distribution XML file at runtime is essentially the same whether you use it in a URL or a command line. Include the options:

destination=filename.xml distribute=yes 

where filename is the name of the distribution XML file. You are required to specify either the relative or absolute path of the XML file. For example, for Windows, you might specify:

destination=c:\%ORACLE_HOME%\reports\distribution\filename.xml distribute=yes 

For UNIX, you might specify:

destination=$ORACLE_HOME/reports/distribution/filename.xml distribute=yes 

For example, the full command in a URL would be similar to:


The paths in these examples are used for illustrative purposes only. There is no requirement for where you store your distribution XML files. You can store them wherever you like.


In some cases, Microsoft Internet Explorer ignores the mimetype of a URL's return stream and instead sets the type by looking at the URL. This can be a problem when you are using the distribution feature of Oracle Reports Services because your URL might end with the destination parameter; for example:

...distribute=yes destination=c:\oracle\reports\distribution\mydist.xml

In this scenario, your URL ends with the extension .xml and Internet Explorer treats the return stream as XML, when in fact it is HTML. As a result, you will receive a browser error. To work around this issue, you should never use recognized file extensions at the end of a URL. In the preceding example, you could switch the positions of the distribute and destination parameters in your URL.

For detailed information on running reports from command lines and URLs and using the cgicmd.dat file, see Chapter 18, "Running Report Requests".