|
RSS Feed - WebSphere MQ Support
|
RSS Feed - Message Broker Support
|
 |
|
Coding Try Catch ... |
« View previous topic :: View next topic » |
Author |
Message
|
NikoP |
Posted: Thu Mar 18, 2004 6:55 am Post subject: Coding Try Catch ... |
|
|
Novice
Joined: 08 Dec 2003 Posts: 16
|
Hi !
I'm using WMQI 2.1 + CSD4
My question :
I want to code a java-like try-catch without using the trycatch block provided by WMQI.
I want to specify directly in my ESQL code the error code returned.
For example, I'd like to have something like that :
DECLARE that, this CHAR;
SET that = '12B4';
TRY
this = CAST(that AS DECIMAL)
CATCH
THROW USER exception catalog 'MyCatalog' message 1234 values ('not a numeric value');
Does it exist ? Is it possible to de someting approaching but without the trycatch node ?
Thanks in advance ! |
|
Back to top |
|
 |
JLRowe |
Posted: Thu Mar 18, 2004 8:56 am Post subject: |
|
|
 Yatiri
Joined: 25 May 2002 Posts: 664 Location: South East London
|
Exception handling in MQSI is very primitive. There is no ESQL try/catch construct and you cannot nest Try/Catch nodes. The only good thing is the failure terminal on compute nodes that allows you to catch errors on just that node. |
|
Back to top |
|
 |
sanjoo |
Posted: Tue Oct 30, 2007 10:21 am Post subject: |
|
|
 Acolyte
Joined: 26 Oct 2005 Posts: 65
|
even in ESQL 6.0, can't I code try catch esql block? _________________ Sanjoo
Keep smiling
 |
|
Back to top |
|
 |
jefflowrey |
Posted: Tue Oct 30, 2007 10:27 am Post subject: |
|
|
Grand Poobah
Joined: 16 Oct 2002 Posts: 19981
|
sanjoo wrote: |
even in ESQL 6.0, can't I code try catch esql block? |
Please don't re-open three year old threads!
No, v6.0 does not have a Try/Catch statement in ESQL.
You can declare an error handler, though, which acts the same way. It's just not try/catch. _________________ I am *not* the model of the modern major general. |
|
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
|
|
|
|