|
RSS Feed - WebSphere MQ Support
|
RSS Feed - Message Broker Support
|
 |
|
Control calling Stored procedure in Compute node |
« View previous topic :: View next topic » |
Author |
Message
|
Yanghui |
Posted: Tue Sep 09, 2003 9:30 am Post subject: Control calling Stored procedure in Compute node |
|
|
Disciple
Joined: 08 May 2002 Posts: 151 Location: Dublin, Ireland
|
Hi, there,
Hope somebody know the answer.
In my msgflow, an Oracle Stored Procedure is called in one Compute node. I want to have some control of this. What I want to achieve is that if the calling is successful, my ESQL goes one path while if the calling fails (ODBC problem or access denied, etc), my ESQL should continue with a flag. I don't want the whole message process backout if calling external procedure fails.
I don't know if this is achievable. Can somebody please let me know? Many thanks in advance.
Best regards
-Yanghui |
|
Back to top |
|
 |
Craig B |
Posted: Tue Sep 09, 2003 9:47 am Post subject: |
|
|
Partisan
Joined: 18 Jun 2003 Posts: 316 Location: UK
|
Hi,
In V2.1, on the Advanced tab of the Compute node you will find an attribute called "Throw Exception on Database Error" and by default this will be ticked. If you uncheck this, then this will mean you will handle database errors yourself. ESQL has four database state indicators called SQLCODE, SQLSTATE, SQLERRORTEXT an SQLNATIVEERROR. After a database call, these should contain results for the first SQL generated as part of your database activity. These will allow you to examine the results and then either continue, or throw an error if you cant handle the error (using the ESQL THROW statement for example). For further information on these database state functions, please see the ESQL reference.
I have never personally tried this with Database stored procedure activity, but it definitely works for standard database activity through SELECTs, INSERTS etc.
Hope this helps. _________________ Regards
Craig |
|
Back to top |
|
 |
Yanghui |
Posted: Wed Sep 10, 2003 4:12 am Post subject: |
|
|
Disciple
Joined: 08 May 2002 Posts: 151 Location: Dublin, Ireland
|
Hi, there,
Thanks a lot. It's very helpful indeed.
Best regards
-Yanghui |
|
Back to top |
|
 |
Yanghui |
Posted: Wed Sep 10, 2003 9:10 am Post subject: |
|
|
Disciple
Joined: 08 May 2002 Posts: 151 Location: Dublin, Ireland
|
Hi, Craig,
Unfortunely it doesn't work for calling Oracle Stored procedure. The whole message processing still backed out after procedure call failure. I did untick "Throw Exception on Database Error". Is there something I have been missing?
Many thanks
-Yanghui |
|
Back to top |
|
 |
|
|
 |
|
Page 1 of 1 |
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
|
|
|