SRW.RUN_REPORT Parameters

On a non-Web publishing, what would the following parameter be set as in the RUN_REPORT procedure
Gateway,Server & CMDkey
I have a report created and I want to call this in the PL/SQL block using SEW package, can I do that without having the HTTP server running. I dont need this report to be called from the Web Browser.
What would be the values that would be set for the Gateway then?
Can you please help me.
TiA,
Shri

SRW.RUN_REPORT('report=ports paraform=no'|| :port));
in above syntax what is the error
please reply
You have two closing parenthesis that's why.-------------------------------------------------------------------------------
Where to put the code:
normally... You will put the code in before report trigger.
to define the parameter...
srw.run_report('parameter1=param_value');
insert ----> parameter1=param_value <-- somewhere in the comand line, there should be no problem with that.

Similar Messages

  • FUNCTION IS NOT WORKING WHEN RUN IN SRW.RUN_REPORT, URGENT

    Hi,
    I have a report. it has got 1 Query and 2 groups.
    Q1
    |
    |
    __G1__
    |F1 |
    |F2 |
    |F3 |
    |
    |
    |
    __G2__
    |Items|
    |Sales|
    | Qty|
    |Store|
    |Func4|
    |Func5|
    |Func6|
    The Query looks like above. Now In the report I have a 3 User parameters . For Each record in G2 the functions Func4,Func5 and Func6 adds the value to the user parameters at the report level.
    Now the Func1,Func2,Func3 takes the value of last 4 record for each item at each G1 Level and devides it by 4 and prints . As an example given below
    ITEMS-----SALES-------QTY-----------STORE
    10001-----10000-------200-------------100
    10001-----20000-------500-------------200
    10001-----15000-------350-------------175
    10001-----45000-------650-------------225
    10001-----50000-------700-------------300
    AVERAGE==>32500-------550-------------225 ==> Calculated by F1,F2,F3
    20001-----70000-------900-------------400
    20001-----30000-------600-------------350
    20001-----20000-------500-------------300
    20001-----25000-------450-------------275
    20001-----35000-------550-------------225
    20001-----65000-------800-------------400
    AVERAGE==>36250-------650-------------300 ==> Avg of last 4 records
    This report takes an parameter which is part of the Where condition of the Query Q1. If I run this report from the report builder and provide the value for the parameter then the report runs fine printing the exact values. If I run the report from another report(which I have to do, due to circumstances) using SRW.Run_Report and pass the parameter in the same command. The the function FUNC4, FUNC5, FUNC6 does not do the addition, as a result the Func1,Func2,Func3 returns 0. I dont know why this is happenning .
    This is very very URGENT, My project manager is on my head to finish it ASAP. Please help.
    Thanks
    Feroz

    Hi Toby and Danny,
    Thanks for the quick reply. I dont think I am having an interdependancy of the functions. Here is an sample what two functions do at each level
    Func6 =========> This function at group level G2
    begin
    -- To initialize the user parameter for each new item.
         If :CNT = 1 Then
              :Wk4_Pos_Qty := 0;
         End If;          
    -- to add the qty value to the user parameter for last 4 records. Uchange is the no of records for each item     
    If :CNT >= :UCHANGE - 3 Then
         :Wk4_Pos_Qty := :Wk4_Pos_Qty + :Qty;
    End If;     
    return 0;
    end;
    Func3 ======> this function at group level G1
    Begin
    -- if no of records are less than 4 then devide by the no of records or devide by 4.
         If :UChange < 4 Then
                   return((:Wk4_Pos_Qty + :Qty) / :UChange);
         Else
                   return((:Wk4_Pos_Qty + :Qty)/ 4);     
         End If;     
    end;
    Here Wk4_Pos_Qty is the User parameter created to hold the calue for the Um of last 4 records Qty.
    I tried to modify the Func3 so that it looks like this
    Func3
    begin
    srw.reference(:Wk4_Pos_Qty);
         If :UChange < 4 Then
                   return((:Wk4_Pos_Qty + :Qty) / :UChange);
         Else
                   return((:Wk4_Pos_Qty + :Qty)/ 4);     
         End If;     
    end;
    But it does not effect anything. I mean its the same. The Wk4_Pos_Qty returns 0 and Func3 returns 0.
    Any Suggestions .
    Thanks
    Feroz

  • Using srw.run_report in report server

    Dear all,
    I'm running a report (report A) on the report server and after it is running (printing output on screen), I need to run report B at the background and save the output of report B to the file system. In the report A's After Report Trigger, I have a srw.run_report function, the syntax is: srw.run_report('server='||v_serverName||' report='||v_reportName||' batch=yes destype=file desname=/tmp/output.pdf desformat=pdf p_startdate=''12-JUN-2003'' p_enddate=''14-JUN-2003'''). When I run the above syntax (without the server name part) in report builder, it works fine. But I couldn't get it working on the report server. Each time report A runs, report B couldn't be run at all (no job id was given or scheduled). Could anyone give me an idea on whether srw.run_report could be used in the report server?
    Many thanks for your urgent help.
    Rose

    Can I use this build it to run itself? I mean in your case run report A?
    our report is launched from servelet. because of some security issues, I would like to use this built in to change it to command line after user enter all the parameters through the parameter form.
    thanks.

  • SRW.RUN_REPORT Passing parameter

    Hello,
    I am calling a report from another report.
    Like the example in help, I have my call in the before report trigger.
    If I call a report that does not need a parameter, it works great. However I cannot make it work when passing a parameter in.
    here is what I have:
    srw.run_report('report=h:\reports\GQR003GL batch=yes destype=printer p_break='||:break||' p_group_quote_iid='||:group_quote_iid);
    Why is this not working?

    Hello Chris,
    You can have a SRW.RUN_REPORT call in your BeforeReport Trigger. Please try coding your trigger something like the one below. Take care to include the white spaces delimiters between consecutive parameters when appending them to the commandline string.
    function BeforeReport return boolean is
    cmdline varchar2(200);
    begin
    cmdline := 'BATCH=YES';
    cmdline := cmdline || ' DESTYPE=PRINTER';
    cmdline := cmdline || ' DESFORMAT=DFLT';
    cmdline := cmdline || ' REPORT=<report_file>';
    cmdline := cmdline || ' P_GROUP_QUOTE_IID=' || :group_quote_iid;
    cmdline := cmdline || ' P_BREAK=' || :break;
    srw.run_report(cmdline);
    return (TRUE);
    end;
    Thanks,
    The Oracle Reports Team.

  • Srw.run_report problem with distribute=yes

    srw.run_report distribute=yes is not working for me. When running the report in rwbuilder or using command line rwrun, the distribution works fine.
    The problem is eg. a report on employee, with a group on Dept_no. Dept_no is used as distribution list &<dept_no> i the distriubution Dialog in the Report and repeat on G_dept.,
    The report wil generate a number of reports e.g. Dept_no_10.pdf, Dept_no_20.pdf and so on.
    BUT, the file name Dept_no_10.pdf is containing data from Dept 20, and the file name4d Dept_no_20.pdf contains data from Dept 20.
    So the question is, if the report can distinguish the number of files to generate and the correct name, how come the data is corrupt ?
    Any ideas is wellcome.
    Our installation is 11.2.0.2 and I'm using Reports 9.0.4.0.33.
    The use of srw.run_report distribute=no is working fine.
    The setup is to run from pl/sql calling srw.run_report
    claus
    try for a better example at this link : https://technology.amis.nl/wp-content/uploads/images/Reports%20Bursting.pdf
    This explains classic distribution/bursting of reports, and it works with rwbuilder/rwrun, bur not through srw.run_report

    Hello,
    If you copy the parameters displayed by srw.message and create a BAT file with these parameters
    and rwrun60 :
    rwrun60 <the paremeters displayed by srw.message>
    Does the report run correctly ?
    Regards

  • Hide URL using srw.run_report

    I called a report from a form 10g using RUN_REPORT_OBJECT which hides url.
    Now i called a report with in report using srw.run_report which shows hole url in the browser.
    I want to hide url.

    Can I use this build it to run itself? I mean in your case run report A?
    our report is launched from servelet. because of some security issues, I would like to use this built in to change it to command line after user enter all the parameters through the parameter form.
    thanks.

  • Reports 6 using SRW.RUN_REPORT - problem with transferring variable to new report.

    I have one report "analyse" that calls another report "pdf".
    In "analyse" i have a function pdf_rep:
    FUNCTION PDF_Rep(c_proevenummer varchar2) RETURN boolean IS
    msg char(150);
    BEGIN
    SRW.Run_Report
    ('BATCH=YES
    REPORT=PDF
    DESTYPE=file
    DESFORMAT=PDF
    desname=test1.pdf
    p_proevenummer='||(c_proevenummer) );
    return(true);
    exception
         when srw.run_report_failure then
         msg := srw.geterr_run;
         srw.message(1,'err msg: '||msg);
         return(false);
    END;
    This function is called from BeforeReport-trigger. (or AfterParameterForm-trigger)
    The "pdf" query:
    select proevenummer
    from View_Analyse
    where proevenummer= :p_proevenummer;
    The "pdf" report is run and a test1.pdf file is made BUT the where-clause is NOT performed.
    What do i do wrong ?

    Hello,
    If you copy the parameters displayed by srw.message and create a BAT file with these parameters
    and rwrun60 :
    rwrun60 <the paremeters displayed by srw.message>
    Does the report run correctly ?
    Regards

  • SRW.Run_Report is not working in Reports from 6i to 10g

    Hi,
    I have a report .rdf file that submits another .rdf report using the SRW.Run_Report. This code was working fine in Reports 6i version. We are upgrading the Reports 6i to Reports 10g, and did a small change in the call i.e., Removed the server parameter, and it is not working. This is in Oracle E-Business Suite environment. The first report is called as a Concurrent Program. Here is the call that was working fine in Reports 6i (i.e., Oracle Apps 11i environment)
    srw.run_report('report='||l_source_dir||l_parent_shortname||'.rdf'||
    ' p_user_id='||l_user_id||
    ' p_resp_id='||l_resp_id||
    ' p_appl_id='||l_appl_id||
    ' p_conc_request_id='||
    ' batch=yes mode=character destype=file desname='||l_destination_dir||l_filename||
    ' desformat=verp_i012 p_vendor_id='||dealer_list_rec.vendor_id||
    ' p_trx_date_from='||to_char(l_date_from, 'DD-MON-RRRR') ||
    ' p_trx_date_to='||to_char(l_date_to,'DD-MON-RRRR') ||
    ' p_period_name='||l_period_name ||                                                                      
    ' server='||l_server
    It has been modified to the following for Reports 10g (i.e., Oracle Apps R12 environment)
    srw.run_report('report='||l_source_dir||l_parent_shortname||'.rdf'||
    ' p_user_id='||l_user_id||
    ' p_resp_id='||l_resp_id||
    ' p_appl_id='||l_appl_id||
    ' p_conc_request_id='||
    ' batch=yes mode=character destype=file desname='||l_destination_dir||l_filename||
    ' desformat=verp_i012 p_vendor_id='||dealer_list_rec.vendor_id||
    ' p_trx_date_from='||to_char(l_date_from, 'DD-MON-RRRR') ||
    ' p_trx_date_to='||to_char(l_date_to,'DD-MON-RRRR') ||
    ' p_period_name='||l_period_name
    );

    Thank you for your reply.
    Yes, it's done using MOD-PLSQL version 10.1.2.0.2.
    I did as you said: compared the 2 generated HTML files. It's not that it doesn't generate all tags. It generates all tags but some of them are different, that is it screws them up.
    Here it is some example code.
    For example, in 9i I have the following code:
    div id=div_plus_GENERALE style="cursor:hand; display:none;"
    <td> width=8 </td>
    <td id=butt align=left style="font-family:Verdana,Tahoma;
    font-size: 10px; font-weight: 400; color: '#ffffff';
    background-color: '';
    "onClick="if (butt_clicked) butt_clicked.style.cssText=restore_butt_style;
    butt_clicked=this; restore_butt_style=butt_off_lit;
    this.style.cssText=butt_on_lit;
    var x = document.getElementById('Freccia_' + freccia_old);
    x.style.display = 'none';
    Freccia_sitointer_anagrafica_anagrafica_cliente_punto.style.display='block';
    freccia_old='sitointer_anagrafica_anagrafica_cliente_punto';"
    onMouseOver="this.style.cssText=butt_on_lit;"
    onMouseOut="if (butt_clicked != this) this.style.cssText=butt_off_lit;">Anagrafica Fornitura</td></tr>
    <tr>
    <td height=2></td>
    </tr>
    </table>
    In 10g the HTML code looks like this:
    div id=div_plus_GENERALE style="cursor:hand;"
    <td width=8> </td>
    <td align=left style="font-family:Verdana,Tahoma;
    font-size: 10px; font-weight: 400; color: '#ffffff';
    background-color: '';">
    <a href="sitointer.anagrafica.anagrafica_cliente_punto target="frameCenter"
    onClick="var x = document.getElementById('Freccia_' + freccia_old);
    x.Style.visibility='hidden';
    Freccia_sitointer_anagrafica_anagrafica_cliente_punto.Style.visibility='visible';
    freccia_old='sitointer_anagrafica_anagrafica_cliente_punto';"
    onMouseOver="this.style.cssText=butt_on_lit;"
    onMouseOut="if (butt_clicked != this) this.style.cssText=butt_off_lit;">Anagrafica Fornitura</a></td></tr>
    <tr>
    <td height=2></td>
    </tr>
    </table>
    At this point I don't know what should I investigate next.
    Thank you very much.
    Daniela

  • SRW,Run_Report not working on Report Server

    1 The plan is to do a select in the mother report. Get a number of rows, among them a company name, which the SQL is sorted on.
    2 In the data model I have a function that checks if a global variable is the same as the company name. If not, it will set the global variable equal to the company name, and then it will run a global defined function that starts the SRW.Runreport call that generates a PDF for this company.
    3 Next row the same thing will happen, and maybe the function is run again, or maybe it is the same company, in which case the SRW function will be skipped.
    The report runs nicely from reports builder, but when I try running it on the server it fails with error: REP-1401: 'cf_doc_trans_letterformula': Fatal PL/SQL error occurred. ORA-06508: PL/SQL: could not find program unit being called.
    I use following web link to start the “mother” report: http://Rep_server/reports/rwservlet?SERVER=origo_report&USERID=user%2Fpassw%40tns_name&AUTHID=user2%2Fpassw2&DESTYPE=cache&DESFORMAT=rtf&Report=temp.rdf
    In the temp.rdf the following statement is executed: SRW.Run_Report('BATCH=YES DESTYPE=FILE DESFORMAT=pdf DESNAME='||P_Desname||'.pdf REPORT='||P_REPORT||'');
    Are there any special settings I must make, when running on a Reports Server as opposed to the Reports Ruilder? Do I need a SERVER=REP_SERVER in the SRW.Run_Report parameter list?
    Any suggestions at all will be immensely appreciated.

    Hi,
    Top right cornor has a text box. Type "bobj is undefined" & you would find many KBs, forums & blogs.
    http://www.sdn.sap.com/irj/scn/advancedsearch?query=bobjisundefined
    Thanks,
    Saurabh

  • How to use srw.run_report without userid parameter in 10g

    I have the following function which works fine when I supply the userid parameter.
    Is it possible to run srw.run_report without the userid? If not is there another way to run a batch report to create a file?
    create or replace
    FUNCTION SUNRESDS(vopersorjudicial varchar2)
    RETURN VARCHAR2 as
    myPlist SRW_PARAMLIST;
    myIdent SRW.Job_Ident;
    BEGIN
    myPlist := SRW_PARAMLIST(SRW_PARAMETER('',''));
    srw.add_parameter(myPlist,'GATEWAY','http://xxx.xx.xxx.xx/reports/rwservlet');
    srw.add_parameter(myPlist,'SERVER','rep_172_FRHome1');
    srw.add_parameter(myPlist,'REPORT','d:\oracle\FRHome_1\forms\sunresds.jsp');
    srw.add_parameter(myPlist,'USERID','username/password@databasename');
    srw.add_parameter(myPlist,'DESTYPE','file');
    srw.add_parameter(myPlist,'DESFORMAT','PDF');
    srw.add_parameter(myPlist,'popersorjudicial',vopersorjudicial);
    srw.add_parameter(myPlist,'DESNAME','d:\Reports\unresolved_discrepancies.pdf');
    myIdent := srw.run_report(myPlist);
    return 'Y';
    EXCEPTION
    when others then
    return ('sunresds ' || sqlerrm);
    END;

    Did you solve your problem? How did you do?

  • Forms 6i & SRW.Run_Report does not work on 10g client

    Hello Sir/Madam,
    I'm using 10g client with Forms & Reports 6i.
    FORMS 6i error => for some reason this combination is prompting FRM-10102 & FRM-40039 errors
    Attempted so far => attached the library, complied, it compiles ok, but somehow loses the library file at runtime
    Reports 6i issue => for Reports seems like it does not recognize SRW.Run_report built-in
    Attempted to run without "srw.run_report" it works..
    Please help me understand if any necessary "*.dll" files are missing? if so what might that be?
    Regards,
    Vani Sonti

    When you install Forms and Reports 6i, the correct Oracle client (8) is installed. I don't know what you did exactly, but you shouldn't try to change that.
    You can install the 10g client, but in a separate Oracle home. This way Forms and Reports still use the 8 client.
    FRM-10102 & FRM-40039 errorsThat looks like a problem in your forms60_path registry setting.

  • Font subsetting issue with srw.run_report

    I have PDF subsetting as
    "Courier" = "MSGOTHIC.TTC"
    I have a report emp.rdf. This emp report just displays the data from emp table.
    I have a report dept.rdf. This dept report just displays the data from dept table.
    In the after report trigger of the dept, I added
    srw.run_report(report=emp destype=file desname=emp.pdf desformat=pdf);
    I am running the dept report from command line as
    rwclient server=<servername> userid=<user/pwd@db> report=dept destype=file desname=dept.pdf desformat=pdf
    The report hangs. I tried moving the after report trigger to before report trigger and it fails too.
    Any ideas?

    Hi,
    Can you try running this report from the Reports Builder, ie, use File > Generate to file > pdf, and see if both the master and child files are generated.
    If yes, can you post both server and engine trace file contents (last few lines) of the instance when you run it from the server, and not from Builder.
    Navneet.

  • Error while running SRW.RUN_REPORT

    Hi All,
    I have requirement where i need to generate multiple reports with single request.
    I have created to sample tables test1 and test2 with two columns each.I have created a paper report using first table and saved it as test.rdf in my c: drive and I created the second report using second table and with in Before Report Trigger i called the first report using srw.run_report('report = c:\test1.rdf desformat=screen'); .
    When I ran the second report its showing an error messg REP-1428 :Error while running SRW.RUN_REPORT.
    Can any one help me to resolve this issue.
    Regard
    Srinivas Pusa

    Why can't you use two queries (one for test1 and another for test2) and create many pages (reports) one report? srq.run_report is avoided completely.

  • Diff bet. run_product and srw.run_report

    In reports 6i is there any difference in architecture between using run_product and srw.run_report(which according to 6i doc calls rwrun60.exe)? The reason is I that have the same report submitted by the above two processes produce font difference in the output pdf file. One gives courier and the other gives courier new where as my actual report font is courier.
    Is ther any difference in the architecture?(run_product uses any in-process report server where as rwrun submits to the report server??)?
    Any advice or suggestion or pointers will be highly appreciated!!

    Hi Venkat
    Ensure that your uifont.ali does not have aliases for Courier font under the [Global] or [Printer] section.
    Regards
    Sripathy

  • Doubt in srw.run_report

    hi all,
    i tried to call one report from other using srw.run_report,the below code is working fine
    but i give destype=screen or preview then its getting error.im using report 10g.
    how to use this?
    function BeforeReport return boolean is
    begin
    srw.run_report('batch=yes report=e:\REP\CALL_REPORT\emp.rdf
    destype=file desformat=PDF desname=e:\REP\CALL_REPORT\emp2.PDF');
    return (TRUE);
    end;

    srw.run_report package may not be used in webservice. It does fit to server/client application.

Maybe you are looking for

  • Lock object for KONV table/Cluster table ??

    Hi All, Is it possible to set Lock/Enqueue cluster tables or in my case table:KONV (KNUMV field) ?. OSS provided some programs without locks so was hoping if I could add before performing data manipulation. Regards, Neeth

  • PS11 Organizer. how 2 move 1 file(folder) into another? drag & drop doesnt work...

    as it does in Win. also how can i create a new file/folder to put other files/folders into. ex a new folder names "Flowers" then put all the other files that contain flowers such as folder "red roses" into the "main" file of Flowers. Cant figure it o

  • Clock in Clock Out

    Hi, After running the time evaluation the clock in and clock out corrections is not appearing on the portal. We are using CATS for service provider to enter the clock in and clock out. Is there any back ground jobs which have to be run for the data t

  • How do you create a structured numbering system in mac "pages".

    I used to use microsoft word, but said id give "pages" a go. what im looking to do is to create a structured report, with the headings in the following manner e.g. 1.0      1.1      1.2      1.3           1.3.1           1.3.2           1.3.3      1.

  • Change AS2 file to AS3?

    Hey all! I started a new flash project and accidentally chose Action Script 2 instead of Action Script 3 and didn't realize it until I had already done quite a bit of work in the timeline. Just wondering if there's an easy way to change the document