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 » IBM MQ Java / JMS » Parsing a MQ String message

Post new topic  Reply to topic
 Parsing a MQ String message « View previous topic :: View next topic » 
Author Message
pandrews
PostPosted: Wed Sep 06, 2006 8:31 am    Post subject: Parsing a MQ String message Reply with quote

Newbie

Joined: 06 Sep 2006
Posts: 2

Hi,

I am using the MQ base java api

I currently receive a message with the following string format:

12668800000022222876Y789YHDHDHDHY77778878877

I know the fixed field lengths for each segment of the message.

Is there a why to bind my message to my java objects? By passing in a descriptor file or something? I know I can get the message as a string and then parse it using java but I am trying to find something a bit more managable

Thanks in advance for any help
Back to top
View user's profile Send private message
jefflowrey
PostPosted: Wed Sep 06, 2006 8:50 am    Post subject: Reply with quote

Grand Poobah

Joined: 16 Oct 2002
Posts: 19981

Once you get the bytes from the message, you are left with "how do I marshall and unmarshall a Java object".

That is, there's nothing unique about MQ in your question. It's just like if you stored the same data as a single column in a database, and fetched it back again.


You might look at SDOs, or consider using XML instead of a fixed width structure.
_________________
I am *not* the model of the modern major general.
Back to top
View user's profile Send private message
pandrews
PostPosted: Wed Sep 06, 2006 8:56 am    Post subject: Reply with quote

Newbie

Joined: 06 Sep 2006
Posts: 2

Thanks for the reply

That's what I thought. Unfortunately I am unable to change the message format of the incoming message to xml, otherwise that would be my choice.
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 » IBM MQ Java / JMS » Parsing a MQ String message
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.