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 » XML message to Fixed length

Post new topic  Reply to topic
 XML message to Fixed length « View previous topic :: View next topic » 
Author Message
Tonedef
PostPosted: Mon Feb 26, 2007 4:29 am    Post subject: XML message to Fixed length Reply with quote

Apprentice

Joined: 05 Feb 2007
Posts: 44

I'm looking for some advice on the best way to change an XML message into a fixed length flatfile.
I tried the ResetcontectDescriptor node and setting the message set etc in ESQL. but didn't work just gave me XML out.

I'm using XML to CWF.

data In
<MESSAGE>
<REC_1>
<ELEMENT1>DATA1</ELEMENT1>
<ELEMENT2>DATA2</ELEMENT2>
<ELEMENT3>DATA3</ELEMENT3>
</REC_1>
</MESSAGE>

data Out(padded with spaces
DATA1 DATA2 DATA3<LF>
next records
Back to top
View user's profile Send private message MSN Messenger
Vitor
PostPosted: Mon Feb 26, 2007 4:37 am    Post subject: Reply with quote

Grand High Poobah

Joined: 11 Nov 2005
Posts: 26093
Location: Texas, USA

You're probably going to need a compute or mapping node (or similar) to change the format like that. I'm assuming you already have a message set defined for the output as you mention setting it in the ESQL.

You'll find advice on syntax, use, etc in the Info Centre.
_________________
Honesty is the best policy.
Insanity is the best defence.
Back to top
View user's profile Send private message
Tonedef
PostPosted: Mon Feb 26, 2007 6:33 am    Post subject: Reply with quote

Apprentice

Joined: 05 Feb 2007
Posts: 44

Thanks,

was simple really, needed to make a few changes to the message tree, to allow nilable element REC_1 etc ..
then use,

SET OutputRoot = InputRoot;
SET OutputRoot.Properties.MessageFormat = 'CWF';

jobs a good 'un

unless someone has a better solution.
Back to top
View user's profile Send private message MSN Messenger
broker_new
PostPosted: Mon Feb 26, 2007 8:19 am    Post subject: Reply with quote

Yatiri

Joined: 30 Nov 2006
Posts: 614
Location: Washington DC

Set these values in the Compute Node

SET OutputRoot.Properties.MessageSet ='MessageSetID of CWF MessageSet';
SET OutputRoot.Properties.MessageType='InputMessage';
SET OutputRoot.Properties.MessageFormat='CWF1';


And map the required fileds from the InputRoot to the OutputRoot;
_________________
IBM ->Let's build a smarter planet
Back to top
View user's profile Send private message
Tonedef
PostPosted: Wed Feb 28, 2007 9:21 am    Post subject: Reply with quote

Apprentice

Joined: 05 Feb 2007
Posts: 44

Thanks,

just to add, some how the parser had been set XML changing it to MRM did the trick.
Back to top
View user's profile Send private message MSN Messenger
Display posts from previous:   
Post new topic  Reply to topic Page 1 of 1

MQSeries.net Forum Index » WebSphere Message Broker (ACE) Support » XML message to Fixed length
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.