ASG
IBM
Zystems
Cressida
Icon
Netflexity
 
  MQSeries.net
Search  Search       Tech Exchange      Education      Certifications      Library      Info Center      SupportPacs      LinkedIn  Search  Search                                                                   FAQ  FAQ   Usergroups  Usergroups
 
Register  ::  Log in Log in to check your private messages
 
RSS Feed - WebSphere MQ Support RSS Feed - Message Broker Support

MQSeries.net Forum Index » WebSphere Message Broker (ACE) Support » ESQL THROW EXCEPTION statement

Post new topic  Reply to topic
 ESQL THROW EXCEPTION statement « View previous topic :: View next topic » 
Author Message
EKhalil
PostPosted: Thu May 11, 2006 10:09 am    Post subject: ESQL THROW EXCEPTION statement Reply with quote

Voyager

Joined: 29 Apr 2003
Posts: 99
Location: Boston, MA

From manual:
"...--Check for invoice number lower than permitted range
IF Body.Invoice.InvoiceNo < 100000 THEN
THROW USER EXCEPTION CATALOG 'MyCatalog' MESSAGE 1234 VALUES
('Invoice number too low', Body.Invoice.InvoiceNo);..."

If I follow and code my statement like this
THROW USER EXCEPTION CATALOG 'HUB' MESSAGE 9003 VALUES('Policy Retrieve Reply;;Search for UUID for KeyGroup ',Body.POLICY_REPLY_AREA.PR_POLICY_INFO.PR_PARTY_INFO[KeyIndex].PYRS_PARTY_ID, 'returned empty result set');
I get a deploy error stating BIP2432E: (.PolicyRetrieveHomeownersAndFire.Main, 251.118) : The correlation name 'Body' is not valid. On the other hand if I use InputBody the value of InputBody.POLICY_REPLY_AREA.PR_POLICY_INFO.PR_PARTY_INFO[KeyIndex].PYRS_PARTY_ID is unknown and I still do not know which party Id caused abend (without looking through traces). Is there another way to do this without using variables ??? Is this a bug in the software or misprint in the manual ???
Back to top
View user's profile Send private message Send e-mail
jefflowrey
PostPosted: Thu May 11, 2006 10:19 am    Post subject: Reply with quote

Grand Poobah

Joined: 16 Oct 2002
Posts: 19981

It's neither a bug in the software or a misprint in the manual.

It's, at best, a confusion in your mind.

If you are writing ESQL in a node that can change the message, then you MUST use InputBody or InputRoot. If you are writing ESQL in a node that CAN'T change the message, then you MUST use Body or Root.

If the trace does not show a value for your PYRS_PARTY_ID, then nothing can be done to extract it. If the trace DOES show a value for your PYRS_PARTY_ID, then you aren't accessing it properly when you say InputBody.POLICY_REPLY_AREA.PR_POLICY_INFO.PR_PARTY_INFO[KeyIndex].PYRS_PARTY_ID.
_________________
I am *not* the model of the modern major general.
Back to top
View user's profile Send private message
EKhalil
PostPosted: Thu May 11, 2006 10:55 am    Post subject: Reply with quote

Voyager

Joined: 29 Apr 2003
Posts: 99
Location: Boston, MA

Thanks for clearing up my confusion
Back to top
View user's profile Send private message Send e-mail
Display posts from previous:   
Post new topic  Reply to topic Page 1 of 1

MQSeries.net Forum Index » WebSphere Message Broker (ACE) Support » ESQL THROW EXCEPTION statement
Jump to:  



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
Protected by Anti-Spam ACP
 
 


Theme by Dustin Baccetti
Powered by phpBB © 2001, 2002 phpBB Group

Copyright © MQSeries.net. All rights reserved.