|
RSS Feed - WebSphere MQ Support
|
RSS Feed - Message Broker Support
|
 |
|
Throwing Exception with unexpected data |
« View previous topic :: View next topic » |
Author |
Message
|
rajasri |
Posted: Sat Sep 02, 2006 12:10 am Post subject: Throwing Exception with unexpected data |
|
|
 Centurion
Joined: 11 Jun 2006 Posts: 114
|
hi all, i have tried to throw a user defined exception. i gave the following syntax
SET InvalidUDPChr = SUBSTRING(InvalidUDPChr FROM 1 FOR LENGTH(InvalidUDPChr)-2);
THROW USER EXCEPTION MESSAGE 2951 VALUES(InvalidUDPChr);
i expected the the message in queue to be having the value of the variable InvalidUDPChr. but instead its printing the variable name itself. part of the output is this
<Text>THROW EXCEPTION MESSAGE 2951 VALUES(InvalidUDPChr);</Text>
the variable name is present in the output. would any one help in solving this. |
|
Back to top |
|
 |
ulisesmartins |
Posted: Sun Sep 03, 2006 7:19 am Post subject: |
|
|
Newbie
Joined: 21 Jul 2004 Posts: 5 Location: Bs.As. Argentina
|
Hi!.. have you tried declaring the variable (is it declared?) ? |
|
Back to top |
|
 |
elvis_gn |
Posted: Sun Sep 03, 2006 7:59 pm Post subject: Re: Throwing Exception with unexpected data |
|
|
 Padawan
Joined: 08 Oct 2004 Posts: 1905 Location: Dubai
|
Hi rajasri,
ulisesmartins wrote: |
Hi!.. have you tried declaring the variable (is it declared?) ? |
If she hadn't, the editor would have thrown an error, and not let her deploy, so I doubt thats the cause.
rajasri wrote: |
i expected the the message in queue to be having the value of the variable InvalidUDPChr. but instead its printing the variable name itself. part of the output is this
<Text>THROW EXCEPTION MESSAGE 2951 VALUES(InvalidUDPChr);</Text> |
There would be a Text in the exceptionlist which will tell you the line of code at which the execution stopped...in your case, it is the above throw statement...
But I don't think, this is the exception that you should be looking at, there should have been another UserException segment underneath(the penultimate segment has the Text with the errored line of code, which is as above)...your code seems ok, so i suppose you are not looking in the right place in the exception list...can u please paste the exception message here.
Regards. |
|
Back to top |
|
 |
rajasri |
Posted: Sun Sep 03, 2006 8:22 pm Post subject: exception |
|
|
 Centurion
Joined: 11 Jun 2006 Posts: 114
|
thank u elvis, i have not seen the exceptionlist properly, yes i have found the proper statement. thank u very much for ur suggestion. |
|
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
|
|
|
|