Focal Point
[CLOSED] Return status to JAVA script from report

This topic can be found at:
https://forums.informationbuilders.com/eve/forums/a/tpc/f/7971057331/m/440101971

July 13, 2009, 03:43 AM
Vasantha kumar
[CLOSED] Return status to JAVA script from report
Hi,

We have a reprot that insert data into a table and then display it. We are triggering the report from JAVA script.

My question is in case of exception scenario like Primary key violation etc., how to return the status of the report run i.e. PASS / FAIL to the JAVA script.

Any help would be appreciated. Smiler

Note: i searched in HELP but nothing informative.

This message has been edited. Last edited by: Kerry,


Vasantha kumar
7.1.4/ Unix / OF:EXL2K
July 13, 2009, 05:02 AM
Majid Jeddi
Hi,

Depends on how you update the table. Are you doing that with a simple update or with a stored procedure?

Regards.


WebFocus 7.6.5
AND WebLogic server as web server
sql2005 as database server
July 13, 2009, 06:04 AM
Vasantha kumar
Its a simple SQL insert statement.


Vasantha kumar
7.1.4/ Unix / OF:EXL2K
July 20, 2009, 03:02 PM
Kerry
Hi Vasantha,

There are many techniques on the Techsupport site so you may want to run a quick search. Or, all you might need is something like this:

SQL DB2
DELETE FROM DB2TABLE.CAR
END
-RUN
-IF &RETCODE EQ 'xxx' THEN GOTO yyy; 


Cheers,

Kerry


Kerry Zhan
Focal Point Moderator
Information Builders, Inc.
July 21, 2009, 04:30 AM
Computix
If you use a xmlhttprequest - Objekt in order to execute the update procedure, you can retrieve the page generated by it and parse it in JavaScript.
Either you just search for the Update-Include...Information generated by the MODIFY TABLE or you generate some Output yourself with -TYPE or similar and search for that information.


WF 7.6.6 (MRE,BID, DevStudio, partly RC) on Windows 2003 /Apache/Tomcat
Output: HTML,Excel,PDF,PPT
Adapters: SQL Server, DB2, Oracle