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 » Compound Element question

Post new topic  Reply to topic
 Compound Element question « View previous topic :: View next topic » 
Author Message
TonyD
PostPosted: Tue Dec 17, 2002 5:38 pm    Post subject: Compound Element question Reply with quote

Knight

Joined: 15 May 2001
Posts: 540
Location: New Zealand

Am sure there is a simple answer to this but here goes:

I am mapping XML to MRM (generated from Cobol Copybook). I have a Cobol compound element:

05 POLICYNO
10 FIRST-THREE PIC X(3)
10 LAST-SEVEN PIC X(7)

The XML element is PolicyNo. In my ESQL I 'SET Output.POLICYNO = Input.PolicyNo' (this is not the exact ESQL of course).
The trace shows that the mapping has occurred correctly but I get a Parser Exception that references the 'FIRST-THREE' field and indicates that the output tree that has been created does not match the logical definition.
I would like to be able to set either POLICYNO to a value, or alternatively set FIRST-THREE and LAST-SEVEN individually to values. Can I do this. I was under the impression that all three elements are addressable and that the parser would only object if, for example, I tried to set POLICYNO and FIRST-THREE, or set LAST-SEVEN but did not set FIRST-THREE.
Back to top
View user's profile Send private message Send e-mail
kirani
PostPosted: Tue Dec 17, 2002 7:20 pm    Post subject: Reply with quote

Jedi Knight

Joined: 05 Sep 2001
Posts: 3779
Location: Torrance, CA, USA

POLICYNO is a parent element with 2 child elements, as such it will not contain any value. You should be able to refer to the child element values by using appropriate reference name like, POLICYNO.FIRST-THREE or POLICYNO.LAST-SEVEN.
If you want to assign value from both the fields to your output XML element then use ESQL similar to this,
Code:

SET OutputRoot.XML.Parent.PolicyNo = InputRoot.MRM.XYZ.POLICYNO.FIRST_THREE || InputRoot.MRM.XYZ.POLICYNO.LAST_SEVEN;

_________________
Kiran


IBM Cert. Solution Designer & System Administrator - WBIMB V5
IBM Cert. Solutions Expert - WMQI
IBM Cert. Specialist - WMQI, MQSeries
IBM Cert. Developer - MQSeries

Back to top
View user's profile Send private message Visit poster's website
TonyD
PostPosted: Tue Dec 17, 2002 7:31 pm    Post subject: Reply with quote

Knight

Joined: 15 May 2001
Posts: 540
Location: New Zealand

Thanks for reply....I am going from XML input to MRM output. I could map the incoming 10-character PolicyNo to the two MRM fields with substring but would prefer to just map straight to the group item.
Will I have to redefine POLICYNO (which as you say has no length attribute of its own) with a POLICYNO_X PIC X(10) in order to map the 10 bytes with a single SET statement?
Back to top
View user's profile Send private message Send e-mail
kirani
PostPosted: Tue Dec 17, 2002 8:15 pm    Post subject: Reply with quote

Jedi Knight

Joined: 05 Sep 2001
Posts: 3779
Location: Torrance, CA, USA

sorry, I misunderstood your question!
Yes, you need to redefine POLICYNO group item with POLICYNO_X PIC X(10) element. After doing this you should be able to assign 10 byte long value to this field.
_________________
Kiran


IBM Cert. Solution Designer & System Administrator - WBIMB V5
IBM Cert. Solutions Expert - WMQI
IBM Cert. Specialist - WMQI, MQSeries
IBM Cert. Developer - MQSeries

Back to top
View user's profile Send private message Visit poster's website
TonyD
PostPosted: Tue Dec 17, 2002 8:44 pm    Post subject: Reply with quote

Knight

Joined: 15 May 2001
Posts: 540
Location: New Zealand

Thanks Kirani...I created a little copybook with a 'REFINED' field and loaded it into the CC to see how WMQI deals with it...clear now. Thanks for the advice.
Back to top
View user's profile Send private message Send e-mail
Swathi3
PostPosted: Mon Jun 10, 2013 11:21 pm    Post subject: Handle Single Request - Multiple responses in Message Broker Reply with quote

Newbie

Joined: 10 Jun 2013
Posts: 2

Hi,

We have a situation in which for each single request sent to the backend from a message flow we might get 10 or 14 reply messages from the backend depending on the request message but we have to send only one reply message to the frontend application. Also, we have a tag in the reply message by which we can decide if it's the last response in the series of replies. Can we use MQGET node for this? If yes, can someone clearly explain how to achive this using get message by corellation id?
Back to top
View user's profile Send private message
smdavies99
PostPosted: Tue Jun 11, 2013 1:10 am    Post subject: Reply with quote

Jedi Council

Joined: 10 Feb 2003
Posts: 6076
Location: Somewhere over the Rainbow this side of Never-never land.

Please to not double post. It only serves to get people annoyed.

We don't really like re-opening 11 year old posts either.

It is better to create a new one and reference the old posts.
_________________
WMQ User since 1999
MQSI/WBI/WMB/'Thingy' User since 2002
Linux user since 1995

Every time you reinvent the wheel the more square it gets (anon). If in doubt think and investigate before you ask silly questions.
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic  Reply to topic Page 1 of 1

MQSeries.net Forum Index » WebSphere Message Broker (ACE) Support » Compound Element question
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.