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 » CWF with MinOccur = 0

Post new topic  Reply to topic
 CWF with MinOccur = 0 « View previous topic :: View next topic » 
Author Message
mark.luebinski
PostPosted: Tue Feb 13, 2007 3:45 am    Post subject: CWF with MinOccur = 0 Reply with quote

Acolyte

Joined: 27 Mar 2006
Posts: 56

Dear Masters,

If I define in CWF a simple message

F1 CHAR(6) MinOcc = 1, MaxOcc = 1
F2 CHAR(6) MinOcc = 0, MaxOcc = 1
F3 CHAR(6) MinOcc = 1, MaxOcc = 1

the second MinOcc don't work. Messages with Length = 12 are not accepted. It is possible to say to Broker, he must accept it and assign the values 7 till 12 to F3?

Thank you very much!


Mark
Back to top
View user's profile Send private message
gregop
PostPosted: Tue Feb 13, 2007 4:14 am    Post subject: Reply with quote

Voyager

Joined: 24 Nov 2006
Posts: 81

I don't think you can do that, MinOccurs is largely ignored on CWF.

See CWF / Min Max Occurs

http://publib.boulder.ibm.com/infocenter/wmbhelp/v6r0m0/index.jsp?topic=/com.ibm.etools.mft.doc/ad10490_.htm

It MIGHT work if you have your optional element at the end

F1 CHAR(6) MinOcc = 1, MaxOcc = 1
F3 CHAR(6) MinOcc = 1, MaxOcc = 1
F2 CHAR(6) MinOcc = 0, MaxOcc = -1

If that doesn't work then I think you'll need 2 message sets unless you can include an additional element that is a counter for F2.
Back to top
View user's profile Send private message
kimbert
PostPosted: Tue Feb 13, 2007 4:23 am    Post subject: Reply with quote

Jedi Council

Joined: 29 Jul 2003
Posts: 5542
Location: Southampton

gregop is spot-on. It will work if the optional element is at the end of the message ( assuming that you're using v6 ).
You can define an integer field and refer to it using OCCURS DEPENDING ON.

If all else fails, you can do this:
- parse the input message in the BLOB domain
- inspect its length
- select the appropriate message type from your message set
- use CREATE...PARSE to create the message tree.
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 » CWF with MinOccur = 0
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.