Home » Developer & Programmer » Reports & Discoverer » Error handling in Oracle Reports (Oracle Reports 11g)
Error handling in Oracle Reports [message #451617] Thu, 15 April 2010 13:49 Go to next message
jfsaucier
Messages: 20
Registered: June 2009
Location: Quebec
Junior Member
Hi,

I want to know if there is a way for our development team to know the status of a report when it's launched from Forms. After reviewing rp2rro.pll code, there seems to be no way of doing that...

Here is some pseudo-code from what I would like to do in Forms. (I am not a developer Wink :


launch report
status = get_status_from_launched_report

if status == ok
do something
else
do something else
end


For the moment, all I miss is the way to get_status_from_launched_report...


Thanks a lot for your help.
Re: Error handling in Oracle Reports [message #451623 is a reply to message #451617] Thu, 15 April 2010 15:00 Go to previous messageGo to next message
Littlefoot
Messages: 21808
Registered: June 2005
Location: Croatia, Europe
Senior Member
Account Moderator
If your developers use RUN_REPORT_OBJECT to run the report, they might also use REPORT_OBJECT_STATUS to check what's being done. Possible results are running, canceled, finished, opening_report, enqueued, invalid_job, terminated_with_error, crashed. Would that be enough?
Re: Error handling in Oracle Reports [message #451699 is a reply to message #451623] Fri, 16 April 2010 04:22 Go to previous messageGo to next message
siddiqui88
Messages: 18
Registered: July 2009
Location: Pakistan
Junior Member
use parameter for status.
Re: Error handling in Oracle Reports [message #451700 is a reply to message #451699] Fri, 16 April 2010 04:28 Go to previous messageGo to next message
Littlefoot
Messages: 21808
Registered: June 2005
Location: Croatia, Europe
Senior Member
Account Moderator
A parameter? Could you explain what you mean?

[Updated on: Fri, 16 April 2010 04:28]

Report message to a moderator

Re: Error handling in Oracle Reports [message #451702 is a reply to message #451617] Fri, 16 April 2010 04:31 Go to previous messageGo to next message
siddiqui88
Messages: 18
Registered: July 2009
Location: Pakistan
Junior Member
DECLARE 
	 
	param_id PARAMLIST; 
BEGIN 
	
	param_id:=CREATE_PARAMETER_LIST('tmpdata');
	ADD_PARAMETER(param_id,p_status',TEXT_PARAMETER,:status);
	ADD_PARAMETER(param_id,'PARAMFORM',TEXT_PARAMETER,'NO');
	Add_Parameter(param_id, 'MAXIMIZE', TEXT_PARAMETER, 'YES');
		
	RUN_PRODUCT(REPORTS,
                   'Report_name',
                    SYNCHRONOUS,
                    RUNTIME,
                    param_id,
                    NULL);
	DESTROY_PARAMETER_LIST(param_id);
	
END;

use this code-------

[EDITED by LF: applied [code] tags]

[Updated on: Fri, 16 April 2010 04:53] by Moderator

Report message to a moderator

Re: Error handling in Oracle Reports [message #451705 is a reply to message #451702] Fri, 16 April 2010 04:56 Go to previous messageGo to next message
Littlefoot
Messages: 21808
Registered: June 2005
Location: Croatia, Europe
Senior Member
Account Moderator
This is "status" you were talking about, I guess:
ADD_PARAMETER(param_id, 'p_status', TEXT_PARAMETER, :status);

How will it return report status to the form?
Re: Error handling in Oracle Reports [message #451713 is a reply to message #451617] Fri, 16 April 2010 05:35 Go to previous messageGo to next message
siddiqui88
Messages: 18
Registered: July 2009
Location: Pakistan
Junior Member
if your parameter status is 'Ok' its will show all 'OK' status value
else it show null or Other value what you want to display against status value.
Re: Error handling in Oracle Reports [message #451715 is a reply to message #451713] Fri, 16 April 2010 05:40 Go to previous messageGo to next message
Littlefoot
Messages: 21808
Registered: June 2005
Location: Croatia, Europe
Senior Member
Account Moderator
But, what/who will put "OK" into the status parameter?
Re: Error handling in Oracle Reports [message #451719 is a reply to message #451617] Fri, 16 April 2010 06:40 Go to previous messageGo to next message
siddiqui88
Messages: 18
Registered: July 2009
Location: Pakistan
Junior Member
show me your form view then i will help you?
Re: Error handling in Oracle Reports [message #451723 is a reply to message #451719] Fri, 16 April 2010 06:54 Go to previous messageGo to next message
Littlefoot
Messages: 21808
Registered: June 2005
Location: Croatia, Europe
Senior Member
Account Moderator
I don't have it, but Jean-Francois might. Though, a day is still young in Quebec. Don't hold your breath.
Re: Error handling in Oracle Reports [message #451728 is a reply to message #451617] Fri, 16 April 2010 07:19 Go to previous messageGo to next message
jfsaucier
Messages: 20
Registered: June 2009
Location: Quebec
Junior Member
Yeah, it's still early in Quebec and the morning coffee will be welcome Wink

Thanks a lot for your help and your suggestions. I will forward them to the development team.

I am not on the development team so I can't provide the Forms code. But I will work with them to get a snippet to post here on next Monday.

Again, thanks a lot for the pointers, it will help us to get in the right direction!
Re: Error handling in Oracle Reports [message #452047 is a reply to message #451617] Mon, 19 April 2010 13:11 Go to previous messageGo to next message
jfsaucier
Messages: 20
Registered: June 2009
Location: Quebec
Junior Member
Thank you for your help, REPORT_OBJECT_STATUS has done it for us!
Re: Error handling in Oracle Reports [message #452099 is a reply to message #452047] Tue, 20 April 2010 01:13 Go to previous message
Littlefoot
Messages: 21808
Registered: June 2005
Location: Croatia, Europe
Senior Member
Account Moderator
/forum/fa/2115/0/
Previous Topic: unable to connect database with reports 5i rep to oracle10 g
Next Topic: Report Resver issue
Goto Forum:
  


Current Time: Thu Apr 25 22:10:04 CDT 2024