Home » Developer & Programmer » Reports & Discoverer » calling report 6i from database trigger (winxp, report 6i, oracle 8i)
calling report 6i from database trigger [message #285654] Wed, 05 December 2007 04:15 Go to next message
jitender.sadh
Messages: 86
Registered: May 2007
Member
hi,

i want to know that is it is possible to run a report from database trigger.i am using report 6i and oracle 8i.

regards
jitender.
Re: calling report 6i from database trigger [message #285668 is a reply to message #285654] Wed, 05 December 2007 04:47 Go to previous messageGo to next message
Maaher
Messages: 7065
Registered: December 2001
Senior Member
Why would anyone want that? But: yes, it is possible. You can call OS commands from the database (using a Java Stored Procedure) so it should be possible to invoke a report as well. Note that everything should take place on the database server as you want to get it done server side.

I advise against it though.

MHE
Re: calling report 6i from database trigger [message #285683 is a reply to message #285668] Wed, 05 December 2007 05:17 Go to previous messageGo to next message
jitender.sadh
Messages: 86
Registered: May 2007
Member
ok, is there any other method to call a report from database without using Java Stored Procedure, my mean by using any oracle built in package .
actualy i am trying to run the report by using following code in oracle 8i

1)create or replace trigger TRIGG1 after insert on emp
2)DECLARE
3) myPlist SRW_PARAMLIST;
4) myIdent SRW.Job_Ident;
5)BEGIN
6) myPlist := SRW_PARAMLIST(SRW_PARAMETER('',''));
7) --srw.add_parameter(myPlist,'GATEWAY','http://...');
8 --srw.add_parameter(myPlist,'SERVER','mySVR');
9) srw.add_parameter(myPlist,'REPORT','c:\myReport.RDF');
10) srw.add_parameter(myPlist,'USERID','scott/tiger');
11) myIdent := srw.run_report(myPlist);
12)END;

but i am getting errors.
SQL> show error
Errors for TRIGGER TRIGG1:

LINE/COL ERROR
-------- -----------------------------------------------------------------
2/12 PLS-00201: identifier 'SRW_PARAMLIST' must be declared
2/12 PL/SQL: Item ignored
3/12 PLS-00201: identifier 'SRW.JOB_IDENT' must be declared
3/12 PL/SQL: Item ignored
5/4 PLS-00320: the declaration of the type of this expression is incomplete or malformed


regard
jitender.



Re: calling report 6i from database trigger [message #285700 is a reply to message #285683] Wed, 05 December 2007 05:54 Go to previous message
Maaher
Messages: 7065
Registered: December 2001
Senior Member
Of course you get errors. The SRW packages are for CLIENT SIDE REPORTS PL/SQL. Oh boy. No, you're a bit off track.

MHE
Previous Topic: REP-3335 aaaaz 36
Next Topic: Printing on Preprinted 8.5" x 7" continuous paper
Goto Forum:
  


Current Time: Sat Nov 30 02:57:24 CST 2024