Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

calling oracle reports in forms

Status
Not open for further replies.

rk68

Programmer
Jul 15, 2003
171
IN
I'm using Oracle 9i forms. How do i call an oracle report in forms. I have heard about run_report_objects & tried using it but didn't work.
I have created a button in form & on when button click trigger, I tried using the run_report_objects ( the example
as given in help) but didn't work.

TIA

Raj
 
I'm getting error FRM-41219: Cannot find report-Invalid ID
& FRM-40738 : Argument 1 to builtin RUN_REPORT_OBJECT cannot be null.

I have done all this -
====================================
Created a simple form with button for calling that report.
Created a new reports server service as following (in Command Prompt):
c:> rwserver -install repserver90 autostart=yes
Created a Report object and in the Property Palette for Reports object, enter the following:
Name: rep_name(This name is given in Run_Report Object
Filename: C:\reports\rep.rdf
into REPORTS_PATH environment variable
Report Destination Type: CACHE
Report Destination Format: HTML
Report Server: repserver90

In the form on when_button_pressed trigger, I've put the following code:-
===================================
DECLARE
repid REPORT_OBJECT;
v_rep VARCHAR2(100);
rep_status VARCHAR2(20);
BEGIN
repid := FIND_REPORT_OBJECT('REPORT10');
v_rep := RUN_REPORT_OBJECT(repid);
rep_status := REPORT_OBJECT_STATUS(v_rep);
WHILE rep_status in ('RUNNING','OPENING_REPORT','ENQUEUED')
LOOP
rep_status := report_object_status(v_rep);
END LOOP;
END;
======================
Please let me know if I have to anything more ?
 
I can't tell from your description if the report attached to your form is called 'REPORT10' or something else.

Check for the reports existence using ID_NULL(v_rep) before the call to run_report_object.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top