jueves, 2 de enero de 2014

LLamar a un report de oracle desde linea de comandos

LLAMAR DESDE LINEA DE COMANDOS

An Oracle Reports command on the command line generally has the following form:

executable_name keyword=value, keyword=value, ...

where each keyword=value pair is called a command line option.

Keywords must be specified and can be used in any order following the executable name.

NOTAS DE USO GENERAL EN LINEA DE COMANDOS

    No spaces should be placed before or after the equal sign of an option.
    Separate options with one or more spaces; do not use commas to separate options.

    Values may be in single or double quotes. The effect of single or double quotes is operating system-specific.

    The keyword= part of all options is not case-sensitive. The value portion may be case-sensitive, depending on your operating system.

    To pass a single quote from the command line, you must enter two quotes (one quote as an escape and one as the actual quote). For example:

    rwrun REPORT=myrep DESTYPE=file DESNAME=run.out BATCH=yes p_value="Roy''s Batch Report"

    Full pathnames are supported for all file refreences (for example, DESNAME=/revenues/q1/nwsales). If you do not specify the full path name, the Oracle Reports file searching method is used to find the file. If you do not specify a path for a keyword value that includes a file name, the Reports Server will try to find the file from the REPORTS_PATH environment variable.

    All file names and paths specified in the client command line refer to files and directories on the server machine, except for any file specified for the following command line keywords:

        CMDFILE=filename. In this case, the CMDFILE specified is read and appended to the original command line (of which CMDFILE is a part) before being sent to the Reports Server. The runtime engine does not reread the command file

        DESNAME=filename DESTYPE=LOCALFILE. In this case, DESNAME refers to files on the client machine.


PALABRAS QUE SE PUEDEN USAR

 En el enlace de la fuente del articulo, se pueden ver todas las palabras que podemos usar como parametros.

rwclient

rwclient (Reports Client) parses and transfers a command line to the specified Reports Server.
All file names and paths specified in the client command line refer to files and directories on the server machine, except for any file specified for the following command line keywords:
  • CMDFILE=filename. In this case, the CMDFILE specified is read and appended to the original command line (of which CMDFILE is a part) before being sent to the Reports Server. The runtime engine does not reread the command file
  • DESNAME=filename DESTYPE=LOCALFILE. In this case, DESNAME refers to files on the client machine.
Refer to Table A-1 for the keywords that can be used with rwclient.

Examples
Example 1: Running a paper report to cache
rwclient server=myrepserv report=test.rdf userid=scott/tiger@mydb desformat=pdf DESTYPE=cache
 
Example 2:  Sending report output to a file
rwclient server=myrepserv report=test.rdf userid=scott/tiger@mydb desformat=pdf DESTYPE=file DESNAME=c:\mydir\test
 
Example 3:  Sending report output to a printer
rwclient server=myrepserv report=test.rdf userid=scott/tiger@mydb desformat=pdf DESTYPE=printer DESNAME=myprinter
 
Example 4: Sending report output through e-mail
rwclient server=myrepserv report=test.rdf userid=scott/tiger@mydb desformat=pdf DESTYPE=mail DESNAME="emp1@comp.com, emp2@comp.com" cc="emp3@comp.com" bcc="mgr@comp.com" replyto="me@comp.com" from="me@comp.com"
 
Example 5:  Sending report output to WebDAV (any WebDAV server or OracleAS Portal WebDAV)
rwclient server=myrepserv report=test.rdf userid=scott/tiger@mydb desformat=htmlcss DESTYPE=webdav DESNAME="http://myusername:mypassword@mywebdavserv.com/mydir/test.html"
 
Example 6:  Sending report output to OracleAS Portal
rwclient server=myrepserv report=test.rdf userid=scott/tiger@mydb DESTYPE=oracleportal desformat=PDF PAGEGROUP=mypagegrp OUTPUTPAGE=reports_output ITEMTITLE=pushtoportal STATUSPAGE=result
 
Example 7:  Sending XML PDS report output to a file
rwclient server=myrepserv report=myxmlpdstest.rdf DESTYPE=file desformat=PDF desname=c:\mydir\my.pdf
 
Example 8:  Sending JDBC PDS report output to a file
rwclient server=myrepserv report=myjdbcpdstest.rdf DESTYPE=file desformat=PDF desname=c:\mydir\myxml.pdf p_jdbcpds=sybuser/sybpwd@server1.mydomain.com:1300

 
Example 9:  Distributing a report output to multiple destinations:
rwclient server=myrepserv report=test.rdf userid=scott/tiger@mydb DISTRIBUTE=yes DESTINATION=c:\mydistribute.xml
 
Example 10:  Running scheduled reports
rwclient server=myrepserver report=test.rdf SCHEDULE="every first fri of month from 15:53 Oct 23, 1999 retry 3 after 1 hour" destype=file desformat=pdf desname=test.pdf
 
Example 11:  Using a secured Reports Server
rwclient server=myrepserv report=test.rdf userid=scott/tiger@mydb desformat=pdf destype=file desname=test.pdf AUTHID=myadmin/myadmin
 
Example 12:  Running a report with e-mail notification
rwclient server=myrepserver report=test.rdf userid=scott/tiger@mydb destype=file desformat=pdf desname=test.pdf NOTIFYSUCCESS="emp@comp.com" NOTIFYFAILURE="admin@comp.com"
 
Example 13:  Running a report that specifies a URL to be fetched with the URL engine
rwclient server=myrepserver report=testExecutables That Use.rdf userid=scott/tiger@mydb destype=file desformat=pdf desname=test.pdf JOBTYPE=rwurl URLPARAMETER="http://www.oracle.com"
 
Example 14:  Running a report with traces
rwclient server=myrepserver report=test.rdf userid=scott/tiger@mydb destype=file desformat=pdf desname=test.pdf TRACEOPTS=trace_all


 

rwrun

rwrun (Reports Runtime) runs a report using the OracleAS Reports Services in-process server.

Note:
It is recommended that you use rwrun for testing purposes only. Use rwservlet and rwclient in your production environment to take full advantage of the power of OracleAS Reports Services.

Refer to Table A-1 for the keywords that can be used with rwrun.


Examples
Example 1:  Customizing a report
rwrun userid=scott/tiger@mydb report=emp.rdf CUSTOMIZE=empcustomize.xml destype=file desformat=pdf desname=emp.pdf
 
Example 2: Sending report output to a file
rwrun report=test.rdf userid=scott/tiger@mydb desformat=pdf DESTYPE=file DESNAME=c:\mydir\test.pdf
 
Example 3:  Sending report output to a printer
rwrun report=test.rdf userid=scott/tiger@mydb desformat=pdf DESTYPE=printer DESNAME=myprinter
 
Example 4:  Sending report output through e-mail
rwrun report=test.rdf userid=scott/tiger@mydb desformat=pdf DESTYPE=mail DESNAME="emp1@comp.com, emp2@comp.com" cc="emp3@comp.com" bcc="mgr@comp.com" replyto="me@comp.com" from="me@comp.com"
 
Example 5:  Sending report output to WebDAV (any WebDAV server or OracleAS Portal WebDAV)
rwrun report=test.rdf userid=scott/tiger@mydb desformat=htmlcss DESTYPE=webdav "DESNAME"="http://myusername:mypassword@mywebdavserv.com/mydir/test.html" 
 
Example 6:  Sending XML PDS report output to a file
rwrun report=myxmlpdstest.rdf destype=file desformat=PDF desname=c:\mydir\my.pdf 
 
Example 7:  Sending JDBC PDS report output to a file
rwrun report=myjdbcpdstest.rdf destype=file desformat=PDF desname=c:\mydir\myxml.pdf P_JDBCPDS=sybuser/sybpwd@server1.mydomain.com:1300 
 
Example 8:  Distributing report output to multiple destinations
rwrun report=test.rdf userid=scott/tiger@mydb DISTRIBUTE=yes DESTINATION=c:\mydistribute.xml
 
Example 9:  Using a secured Reports Server
rwrun report=test.rdf userid=scott/tiger@mydb desformat=pdf destype=file desname=test.pdf AUTHID=myadmin/myadmin
 
Example 10:  Running a report with e-mail notification
rwrun report=test.rdf userid=scott/tiger@mydb destype=file desformat=pdf desname=test.pdf NOTIFYSUCCESS="emp@comp.com" NOTIFYFAILURE="admin@comp.com"
 
Example 11:  Running a report with trace enabled
rwrun report=test.rdf userid=scott/tiger@mydb destype=file desformat=pdf desname=test.pdf TRACEOPTS=trace_prf TRACEMODE=trace_replace


 Fuente: http://docs.oracle.com/html/B14048_02/pbr_cla.htm




No hay comentarios:

Publicar un comentario