SRW Package
Hi All,
In order to run Report from pl/sql someone in the forum,
had suggested to install the SRW package,
please anyone help in find the code for install in the pl/sql
Thanks and Regards
Raj
You have to run a few scripts, like srwapiins.sql, which are found in <9iAS home>\reports\admin\sql
See:
http://download-west.oracle.com/docs/html/A92102_01/pbr_evnt.htm#1005558
Similar Messages
-
Using SRW package to send a report via email
Hi,
Please can someone please help me resolve this issue I have been facing in using the srw package
I have configured a report server and was trying to use the srw package to send a report out to our customers when there is an update on a particular table.
I have succesfully use this same procedure to generate the same report to an output file and it was ok but anytime I try to generate the report as a mail and send to a DESNAME, i get mail server unavailable.
Below is the procedure i try to execute:
procedure testrep(new_name in varchar2) as
myPlist SRW_PARAMLIST;
myIdent SRW.Job_Ident;
BEGIN
myPlist := SRW_PARAMLIST(SRW_PARAMETER('',''));
srw.add_parameter(myPlist,'GATEWAY','http://technorth4:7780/reports/rwservlet');
srw.add_parameter(myPlist,'SERVER','rep_technorth4');
srw.add_parameter(myPlist,'REPORT','c:\gens\name.rdf');
srw.add_parameter(myPlist,'USERID','gens/[email protected]');
srw.add_parameter(myPlist,'AUTHID','orcladmin/password1@orcl');
srw.add_parameter(myPlist,'DESTYPE','MAIL');
srw.add_parameter(myPlist,'DESFORMAT','PDF');
srw.add_parameter(myPlist,'FROM','[email protected]');
srw.add_parameter(myPlist,'DESNAME','[email protected]');
srw.add_parameter(myPlist,'T1',new_name);
myIdent := srw.run_report(myPlist);
END;
when i now start debugging i got this error:
SQL> set serveroutput on
SQL> exec srw.start_debugging
* WELCOME TO EVENT-BASED-REPORTING API *
* API-Version : 9i *
* (C) Oracle Corporation, 2000 - 2002 *
* Debugging turned ON **************************
PL/SQL procedure successfully completed.
SQL> exec testrep('TOPE');
*** Length of Paramlist : 1
OK : Parameter added : GATEWAY=http://technorth4:7780/reports/rwservlet
*** Length of Paramlist : 2
OK : Parameter added : SERVER=rep_technorth4
*** Length of Paramlist : 3
OK : Parameter added : REPORT=c:\gens\name.rdf
*** Length of Paramlist : 4
OK : Parameter added : USERID=gens/[email protected]
*** Length of Paramlist : 5
OK : Parameter added : AUTHID=orcladmin/password1@orcl
*** Length of Paramlist : 6
OK : Parameter added : DESTYPE=MAIL
*** Length of Paramlist : 7
OK : Parameter added : DESFORMAT=PDF
*** Length of Paramlist : 8
OK : Parameter added : [email protected]
*** Length of Paramlist : 9
OK : Parameter added : [email protected]
*** Length of Paramlist : 10
OK : Parameter added : T1=TOPE
Starting run_report: building url
*** Building URL (RUN_REPORT)
OK : URL built :
http://technorth4:7780/reports/rwservlet?SERVER=rep%5Ftechnorth4&REPORT=c%3A%5Cg
ens%5Cname%2Erdf&USERID=gens%2Fgens%40technorth%2Eworld&AUTHID=orcladmin%2Fpassw
ord1%40orcl&DESTYPE=MAIL&DESFORMAT=PDF&FROM=tope%5Folowosale%40gtbplc%2Ecom&D
*** Submitting HTTP Request
*** using URL
:http://technorth4:7780/reports/rwservlet?SERVER=rep%5Ftechnorth4&REPORT=c%3A%5C
gens%5Cname%2Erdf&USERID=gens%2Fgens%40technorth%2Eworld&AUTHID=orcladmin%2Fpass
word1%40orcl&DESTYPE=MAIL&DESFORMAT=PDF&FROM=tope%5Folowosale%40gtbplc%2Ecom&DES
OK : Request submitted - Return stream : <?xml version = '1.0' encoding =
'ISO-8859-1' standalone = 'yes'?>
<serverQueues>
<error code="50138"
component="REP" message="Mail server is not available"/>
</serverQueues>
OK : Request submitted - Length of stream : 182
*** XML-Parsed - Following Structure discovered :
*** Checking elements!
serverQueues ()
*** Checking attributes!
error
*** Checking attributes!
__code = 50138
__component = REP
__message = Mail server is not available
*** Finished Parsing XML
Getting value for element: job
Getting value for element: error
*** Requesting value for Attribute error.component [REP]
Getting value for element: error
*** Requesting value for Attribute error.code [50138]
Getting value for element: error
*** Requesting value for Attribute error.message [Mail server is not available]
REP-50138:Mail server is not available
BEGIN testrep('TOPE'); END;
ERROR at line 1:
ORA-20999:
ORA-06512: at "GENS.SRW", line 284
ORA-06512: at "GENS.SRW", line 815
ORA-06512: at "GENS.TESTREP", line 17
ORA-06512: at line 1
Please can someone help me with this. I can connect to the mail server using the telnet mailservername port,i get a 220 message with ***** .
I have updated d report configuration file with the mailserver name, and d proxyinfo.xml too.I put it to bypass proxy for d mail server address and also inlclude the proxy ip and port.
Kindly assist me as it is urgent.
Thank you.You are in the wrong forum. Please try the Reports.<br><br>
Regards,
Rob. -
SRW Package in Reports 2.5
I am having trouble running SRW.RUN_REPORT from batch mode in PL/SQL. First of all, I'm having trouble locating the SRW package that is standard in Reports 2.5, in order to to create the package. Do I need to locate the Version 2.5 disk and try a reinstall? Or is it as simple as creating a Public Synonym?
The PL/SQL code is: SRW.RUN_REPORT (module=mname batch=yes....
The Error is: "module" must be declared.
This tells me that the SRW package is not known. Else it would not ask me to make a declaration of the keyword "module". Big Thanks to anyone who can help.What are the default location for log files,trace for forms server and reports server in weblogic.That depends on which Reports Server you are using (Standalone or Inprocess). Here are the locations for both:
Standalone*
$ORACLE_INSTANCE/diagnostics/logs/ReportsServerComponent/<Name of Report Server>/
In-Process*
$DOMAIN_HOME/servers/WLS_REPORTS/logs/reports/
Craig... -
ERROR:SRW Packages to call report from PL/SQL.
Hi,
I am facing the following problem while calling a report from PL/SQL Block.
This is my code
SRW.Start_Debugging;
MYPLIST :=SRW_PARAMLIST(SRW_PARAMETER('',''));
SRW.ADD_PARAMETER(myPlist,'GATEWAY' ,'http:..............');
SRW.ADD_PARAMETER(myPlist,'USERID' ,'CGIA_AUTO/AUTO_DEV@ipaddress/ORCL');
SRW.ADD_PARAMETER(myPlist,'SERVER' ,'rep_cgian');
SRW.ADD_PARAMETER(myPlist,'REPORT' ,'PGIRCGIC047.rdf');
SRW.ADD_PARAMETER(myPlist,'DESTYPE' ,'file');
SRW.ADD_PARAMETER(myPlist,'DESFORMAT' ,'pdf');
SRW.ADD_PARAMETER(myPlist,'DESNAME' ,'\\ipaddress\CGIA_FormPrint\WatchFolder\OTHERS\'||Z.CS_REMARKS_BL||'_'||Z.CS_CHQ_NO||'_'||M_SEQ_NO||'-'||Z.CS_FLEX_07||'-'||Z.CS_FLEX_08||'.pdf');
SRW.ADD_PARAMETER(myPlist,'PARAMFORM' ,'NO');
SRW.ADD_PARAMETER(myPlist,'P_1' ,Z.CS_BANK_CODE);
SRW.ADD_PARAMETER(myPlist,'P_2' ,Z.CS_BAD_ACNT_NO);
SRW.ADD_PARAMETER(myPlist,'P_3' ,Z.CS_CHQ_BOOK_ID);
SRW.ADD_PARAMETER(myPlist,'P_4' ,Z.CS_CHQ_NO);
SRW.ADD_PARAMETER(myPlist,'P_5' ,Z.CS_CHQ_NO);
MYIDENT:=SRW.RUN_REPORT(MYPLIST);
MYSTATUS := SRW.REPORT_STATUS(MYIDENT);
SRW.STOP_DEBUGGING;
*** Length of Paramlist : 1
OK : Parameter added : GATEWAY=http://...
*** Length of Paramlist : 2
OK : Parameter added : USERID=CGIA_AUTO/AUTO_DEV@ipaddress/ORCL
*** Length of Paramlist : 3
OK : Parameter added : SERVER=rep_cgian
*** Length of Paramlist : 4
OK : Parameter added : REPORT=PGIRCGIC047.rdf
*** Length of Paramlist : 5
OK : Parameter added : DESTYPE=file
*** Length of Paramlist : 6
OK : Parameter added : DESFORMAT=pdf
*** Length of Paramlist : 7
OK : Parameter added :
DESNAME=\\ipaddress\CGIA_FormPrint\WatchFolder\OTHERS\CUST000115_102024_16--.pd
f
*** Length of Paramlist : 8
OK : Parameter added : PARAMFORM=NO
*** Length of Paramlist : 9
OK : Parameter added : P_1=SDNB
*** Length of Paramlist : 10
OK : Parameter added : P_2=7000674257
*** Length of Paramlist : 11
OK : Parameter added : P_3=7000
*** Length of Paramlist : 12
OK : Parameter added : P_4=102024
*** Length of Paramlist : 13
OK : Parameter added : P_5=102024
Starting run_report: building url
*** Building URL (RUN_REPORT)
OK : URL built :
http://ipaddress/reports/rwservlet?&USERID=CGIA_AUTO%2FAUTO_DEV%40ipaddress%2FORCL&SERVER=rep_cgian&REPORT=PGIRCGIC047.rdf&DESTYPE=file&DESFORMAT=
pdf&DESNAME=%5C%5Cipaddress%5CCGIA_FormPrint%5CWatchFolder%5COTHERS%5CCUST00
*** Submitting HTTP Request
*** using URL
:http://ipaddress/reports/rwservlet?&USERID=CGIA_AUTO%2FAUTO_DEV%ORCL&SERVER=rep_cgian&REPORT=PGIRCGIC047.rdf&DESTYPE=file&DESFORMAT
=pdf&DESNAME=%5C%5Cipaddress%5CCGIA_FormPrint%5CWatchFolder%5COTHERS%5CCUST0001
OK : Request submitted - Return stream : <?xml version = '1.0' encoding =
'ISO-8859-1' standalone = 'yes'?>
<serverQueues>
<error code="503"
component="REP" message="You did not specify the name of a
report."/>
</serverQueues>
Here in this case even though i specify the report id in the parameter,debugger message says that 'You did not specify the name'.
The same code is working in some other server and giving the pdf output.
Thanks in advance for any clarification.Hello Chirag,
If you want to invoke and run a report from your PL/SQL code in the database, you can do so by installing and using the SRW package supplied with Reports. This package allows you to run parametrized report jobs on a specified Reports Server from your PL/SQL program and track the job status. Please take a look at the documentation for this package in the Publishing Reports manual on OTN at: http://download-west.oracle.com/docs/html/A92102_01/toc.htm.
On the other hand, if you just need to invoke the Reports Builder program from your PL/SQL routine, you would need to use the default builtin for calling external applications from PL/SQL.
Thanks,
The Oracle Reports Team. -
Hello All,
I've designed web based reports having a web layout. The user usually navigates from one report to another by way of ">
<th <rw:id id="HFMONTH131" breakLevel="RGMONTH1313" asArray="yes"/> class="OraRowHeader" style="font-weight: normal" ><rw:field id="FMONTH131" src="MONTH" breakLevel="RGMONTH1313" breakValue=" " formatTrigger="STYLE1"> F_MONTH </rw:field></th></a>
I'm aware of reports being opened,errors captured,messages displed & programs aborted using the various srw packages when called from inside a program unit.
Is there a way to call a program unit when the user clicks on a particular field which is supposed to be a link to another report instead of the above mentioned hyperlink method. Like for instance we have a formatTrigger for calling a program unit written for manipulating the format of the output.
Regards,
Arun.VHello,
Web Layout only exists in Reports versions >= 9.0.2. In these versions, the object "Button" no more exists.
When the output is displayed, the reports execution is terminated, so it is not possible to call a program unit when the user click on a field.
In the Reports Online Help:
Note: The ability to create a button in the Paper Layout view is no longer supported in Oracle Reports 10g. Use hyperlinks instead. If you open an existing report that contains buttons, the buttons will be converted into text items.
Regards -
hi
i am working on Oracle forms and reports 11g on weblogic. I have used SRW.MESSAGE to display run time message,but it is not showing anything.Is SRW package is not there in reports services 11g.
If not,there is any alternative is there to display message
Edited by: 957551 on May 9, 2013 4:01 AMWhat are the default location for log files,trace for forms server and reports server in weblogic.That depends on which Reports Server you are using (Standalone or Inprocess). Here are the locations for both:
Standalone*
$ORACLE_INSTANCE/diagnostics/logs/ReportsServerComponent/<Name of Report Server>/
In-Process*
$DOMAIN_HOME/servers/WLS_REPORTS/logs/reports/
Craig... -
Srw package: Catching REP- errors
IN SRW package by Philipp Weckerle there's lines that look like those:
r_staRec.JobIdent.JobID := GetValueFromXML(p_XMLDocument, 'job', 'id');
if ((r_staRec.JobIdent.JobID is null) or (r_staRec.JobIdent.JobID = ''))
then -- got error
r_errStr := GetValueFromXML(p_XMLDocument, 'error', 'component') || '-' ||
GetValueFromXML(p_XMLDocument, 'error', 'code') || ':' ||
GetValueFromXML(p_XMLDocument, 'error', 'message');
print_debug_message(r_errStr);
raise REQUEST_FAILED;
else -- no error
I.e. if report fails, I can't get the particular error number. Although it is extracted from XML reply (p_XMLDocument, 'error', 'code'), it is used only to print dubug message and discarded.
The questuins are:
1. Is there any newer version of the package in which that issue was fixed?
2. If no, are we allowed to modify the package ourselves to fulfil our tasks?Your not seeing the built in package for some reason.
Maybe they are missing on your Linux machine.
Reinstall reports there? Examing your environment variables?
Is that rwrun.jar anywhere? -
Oracle report 10g srw package.
hi,
i want to know about srw package in that srw.do_sql where it should be placed?you can check for SRW.DO_SQL built-in procedure in Reports online help.
-
Date formate of Status_Record.QueuedAt and other date fields in SRW package
Hi,
Is the date format of the Status_Record fiields in SRW package are controlled by any DB parameter ?
B'cos it differs between databases for me.The SRW package calls the Reports server. This, in turn, gives the result back in XML format. The DB package parses the XML. The date format is taken from this XML result. So, the setting is somewhere on the Reports server, but I don't know where. There are so many property files.
You see the same date format in the servlet: http://<host>:<port>/reports/rwservlet/getserverinfo? E.g.
Start Time Oct 28, 2008 8:40:24 AM
Check this in your case. -
Hi,
Is it possible that SRW package doesn't work with Oracle Forms 11g Release 1?
For exemple, when I compile a library with "srw.do_sql" comande, the Forms 11g compiler told me that this function is not defined.
What is wrong?SRW package is a reports package I believe ..
I couldn't see this even in Forms 10g . But I have seen this in Reports ..
Do you think it was in Forms also .. -
SRW package not working in Reports 10g (9.0.4)
Dear All,
I am using reports services 10g (9.0.4) for RHEL o/s.we are using SRW pkg in our reports heavily.But when we compile reports in Linux it is showing errors like SRW.message ,SRW.set_field_char,SRW.set_format_mask must be declared.
Though these functions are well written in reports help,it is not at all supporting these functions.
What is solution for this for successfull compilation of reports??
Regards-
Onkar Vidwans
INDIAYour not seeing the built in package for some reason.
Maybe they are missing on your Linux machine.
Reinstall reports there? Examing your environment variables?
Is that rwrun.jar anywhere? -
What is abbrevation of SRW packages
hi
one interviewer asked me builtin packages in reports.
i answered its SRW.Pacakeges. He asked abbrevation of SRW , i simply frustated. What is SRW's full name
thanks in advance
prasanth as.SRW stands for SQL*ReportWriter.
SRW drivers are driver files, which are used to define output files of SRW reports into a certain format during the generation of reports. -
Srw package throwing PRAGMA exception_init(SPECIFY_PROTOCOL, -20002)
I've added srw.ADD_PARAMETER ( plRepParam, 'server_protocol', 'HTTP/1.1' ); to no avail. Any ideas?
Twas muppetry on my part, I had missed http:// from my gateway param setting.
-
SRW server package error.
Apps server 9i r2
I am attempting to run reports using the SRW package which has bee installed in the database but I am getting an incompatibilty between the date format the SRW package is expecting and the date returned from invoking SRW.run_report when the package tries to convert the queued tag into its expected format. The code is;
l_Paramlist := srw_paramlist(srw_parameter('','')) ;
srw.clear_parameter_list(l_Paramlist);
srw.add_parameter(l_Paramlist, 'GATEWAY', 'http://app/reports/rwservlet') ;srw.add_parameter(l_Paramlist, 'SERVER', 'rep_app) ;
srw.add_parameter(l_Paramlist, 'REPORT', 'd:/client/bin/REP0080.REP') ;
srw.add_parameter(l_Paramlist, 'USERID', 'user/pwd') ;
srw.add_parameter(l_Paramlist, 'DESTYPE', 'MAIL') ;
srw.add_parameter(l_Paramlist, 'DESNAME', 'user, add) ;
srw.add_parameter(l_Paramlist, 'DESFORMAT', 'HTML') ;
l_Ident := srw.run_report(l_Paramlist) ;
But I get the following error with trace turned on;
Getting value for element: queued
*** Requesting value for TAG queued [07/07/03 15:48]
l_Paramlist SRW_PARAMLIST ;
ERROR at line 2:
ORA-01849: hour must be between 1 and 12
ORA-06512: at "SYS.SRW", line 290
ORA-06512: at "SYS.SRW", line 774
ORA-06512: at line 19
It appears that the SRW package only accepts dates in the format of MM/DD/YY HH:MI AM which is a problem because the XML is returning the date in the format of DD/MM/YY HH24:MI.
If the problem is that the application server is not setup properly what should I do to rectify the problem.dassdhan wrote:
Hi,
We are using Form/Report 6i.
I tried "SRW.RUN_REPORT in After Report Trigger" with DESTYPE=FILE and it run & created FILE successfully.
But when I tried with DESTYPE=SCREEN,it show error.
Actually, we have 02 reports. We want to use SRW.RUN_REPORT in After Report Trigger in 1st report, so that 2nd report run automatically.
I didn't find any solution in my previous query, but sending again this query with the hope of getting solution.
Kindly guide me.
Thanks.
Dass.
Call/Run Report from a Report!
Please check the restriction of
SRW.RUN_REPORTS
1 If you want parameter values that are entered on the Runtime Parameter Form to be passed in the RWRUN60 string, you must call SRW.RUN_REPORT after the before form trigger.
2 The string that is specified for or passed to this procedure must follow the syntax and case-sensitivity rules for your operating system.
3 No userid should be specified for the SRW.RUN_REPORT procedure. The userid is inherited by the "calling" report.
4 If the parent report that invokes SRW.RUN_REPORT is run in batch, then DESTYPE can only be File, Printer, Sysout, or Mail. Otherwise, DESTYPE can be File, Printer, or Mail.
5 If SRW.RUN_REPORT is used in the PL/SQL for a button, the Runtime Parameter Form will not appear by default when the button is selected. If you want the Runtime Parameter Form to appear, you must specify PARAMFORM=YES in the call to SRW.RUN_REPORT. -
How to view RUN_REPORT_OBJECT buil-in package source code
Ps help.
I'm creating a batch report that will execute from PL/SQL not forms - so I can't use this built-in directly on my PL/SQL procedure. How do I view RUN_REPORT_OBJECT source code and that of the functions that it calls.
Thanks
KhombiYou can't see source code of this package.
You can use srw package. Please see the following link.
http://download-uk.oracle.com/docs/cd/B14099_17/bi.1012/b14048/pbr_evnt.htm
Maybe you are looking for
-
I somehow seem to have changed the Apple id password on my iPad and don't know what it is. When I try to reset it, I'm given the option of having Apple get in touch with me by email. I click on this choice and Apple says the email has been sent - b
-
Display issue with some browser : OnMouse based on An Application Process
Hello, I am playing a little bit with the Application Process and I tried to create something like the Aria Demo (onmouseover="ARIA_DETAIL(this, '#PERSON_ID#')") Indeed, no problem to make it work (using a default template among the 20 provided by Ap
-
XML data Upload in BW ( Webservice issue)
I am following the SDN document of 'How to load XML data into BW' and followed the steps till 19 and 26( BW3.5 need to skip steps in between). As mentioned I have followed the steps to create the web service properly. However while testing I am get
-
Best practices code structure for large projects?
Hi, I come from the Java world where organizing your code is handled conveniently through packages. Is there an equivalent in XCode/Objective C? I'd rather not lump all my observers, entities, controllers, etc in one place under "Classes"...or maybe
-
How does scaling work under Windows 7 with the new MBP with retina display?
After installing Windows in a boot camp partition on the new MacBook Pro, how does scaling work compared to OS X? Does Windows know to have several pixels imitate a single pixel like in OS X when running in 1440 x 900, or is there no scaling effect a