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 strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

calling reports 9i 1

Status
Not open for further replies.

Thameem

Programmer
Sep 18, 2002
30
US
How to call a report 9i rdf from forms 9i,
when used run_report_object,it gives invalid id.
 
Yes, you should use RUN_REPORT_OBJECT. This error probably means misspelled report object (not the same as report module!) name. Can you open the form and look at the name of attached report?

Regards, Dima
 
DECLARE
repid REPORT_OBJECT;
v_rep VARCHAR2(100);
BEGIN
repid := FIND_REPORT_OBJECT('c:\rep_call');
v_rep := RUN_REPORT_OBJECT(repid);
END;

This is how I called the report from form. The name of the report is correct. The report is available in its location mentioned. Still getting invalid id message. Is any setting I have to make with respect to application server(here it is my local machine).What else needs to be done.
 
If you read my post carefully you may probably learn that report object name is not the same as report file name. In this built-in you should use report object name, that is the name of report object existing in your form. On of that object properties is its location.

Regards, Dima
 
When I give the report object name ,
I am getting the "rep-0503 you did not specify the report name"
error.Now the invalid id message is solved
What else needs to be done.
 
Have you specified correct report name in your report object? As to your "what else", I think you need to read about Forms/Reports integration basics.

Regards, Dima
 
When I use the same set of codings and objects in forms 6i
it is working fine.
My What else is meant for any special setting we need to do for forms 9i. If my coding is wrong it would not have worked with 6i also.
 
Haven't you used RUN_PRODUCT, not RUN_REPORT_OBJECT in 6i? Or probably specified report object name that was the same as report module name? I can only guess why it worked with 6i, but your understanding of RUN_REPORT_OBJECT is wrong.

Regards, Dima
 
Its working now. I understand there exists some difference in calling reports in forms 6i and Forms 9i. Thank you for your valuable suggestions.
 
dear thameem and for all

im facing the same problem i can not run my report from the form so please can you help and tell me how you solve it
 
Hi,
Just follow the steps,

Calling Reports from Forms 9i

1. Create a report using Reports 9i and check it whether it is working in paper layout mode.
2. Create a simple form for calling that report.
3. Create a new reports server service as following (in Command Prompt):
c:> rwserver -install repserver90 autostart=yes
4. Create a Report obect and in the Property Palette for Reports object, enter the following:
Name: rep_name(This will be the name given in Run_Report Object0
Filename: C:\reports\rep.rdf
/*<specify full path to your RDF/REP file or make sure this path is included
into REPORTS_PATH environment variable*/
Report Destination Type: CACHE
Report Destination Format: HTML
Report Server: repserver90
5. In the form run the following code to call the report

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;
IF rep_status = 'FINISHED' THEN
/*Display report in the browser*/
WEB.SHOW_DOCUMENT(' substr(v_rep,instr(v_rep,'_',-1)+1)||'?'||'server=repserver90','_blank');
ELSE
message('Error when running report');
END IF;
PAUSE;
END;
 
i did the all step one by one but again i have an error unable to run the report server
 
and please can you repeat again step number 4 i did'nt understand it very well so please just give more details.

report_object where i can find it please give some more details


regards
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top