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 API Support » Conversion of Msgid and Correlid

Post new topic  Reply to topic
 Conversion of Msgid and Correlid « View previous topic :: View next topic » 
Author Message
tanbsj
PostPosted: Tue May 18, 2004 8:29 pm    Post subject: Conversion of Msgid and Correlid Reply with quote

Novice

Joined: 08 Jun 2003
Posts: 16

Hi everyone,

Can anyone advise me on how to convert the Msgid and Correlid from
EBCDIC to ASCII.

I have read somewhere that said Msgid and Correlid will not be automatic converted. Is this true? If true, what are the way to convert
from EBCDIC to ASCII?

Please help.

Thank you in advance.
Back to top
View user's profile Send private message Send e-mail
EddieA
PostPosted: Tue May 18, 2004 10:07 pm    Post subject: Reply with quote

Jedi

Joined: 28 Jun 2001
Posts: 2453
Location: Los Angeles

Quote:
Msgid and Correlid will not be automatic converted. Is this true?

Absolutely. Those fields are defined as BYTE24. Any conversion must be "home grown".

Why do you need to convert them. Perhaps if you explain why you think you need this, someoine may come up with a suitable solution.

Cheers,
_________________
Eddie Atherton
IBM Certified Solution Developer - WebSphere Message Broker V6.1
IBM Certified Solution Developer - WebSphere Message Broker V7.0
Back to top
View user's profile Send private message
tanbsj
PostPosted: Tue May 18, 2004 11:07 pm    Post subject: Reply with quote

Novice

Joined: 08 Jun 2003
Posts: 16

Hi EddieA

Thank you so much for your reply.

The correlid is to use for keeping track of a long messages being
split to a few smaller messages.

We will try to write the convert on the mqput program


Thank you so much
Back to top
View user's profile Send private message Send e-mail
jefflowrey
PostPosted: Wed May 19, 2004 3:44 am    Post subject: Reply with quote

Grand Poobah

Joined: 16 Oct 2002
Posts: 19981

you're going to have trouble if you are actually using these IDs in your code AND you convert them.

Since MQSeries treats them as byte arrays rather than text strings, if you convert them you are going to lose your correlation.

The basic approach to recording them for tracking processes is to convert the byte into a hex string.
_________________
I am *not* the model of the modern major general.
Back to top
View user's profile Send private message
bower5932
PostPosted: Wed May 19, 2004 5:01 am    Post subject: Reply with quote

Jedi Knight

Joined: 27 Aug 2001
Posts: 3023
Location: Dallas, TX, USA

Can't you do something to put your messages into a group rather than using the correlation id to keep track of the pieces? You could use the MD flags of MQMF_MSG_IN_GROUP and MQMF_LAST_MSG_IN_GROUP to do your puts. You could then do your gets by matching on the group id. There are details in the Application Programming Guide/Reference.
Back to top
View user's profile Send private message Send e-mail Visit poster's website AIM Address Yahoo Messenger
tanbsj
PostPosted: Wed May 19, 2004 7:47 pm    Post subject: Reply with quote

Novice

Joined: 08 Jun 2003
Posts: 16

Hi all,

Thank you so much. Will re-study the design again.

Back to top
View user's profile Send private message Send e-mail
kirani
PostPosted: Thu May 20, 2004 6:51 am    Post subject: Reply with quote

Jedi Knight

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

I think if you "convert" the correl-id correctly then there should not be any problem.
For example, Let's say your m/f program sets the CorrelID on a group (nothing to do with MQ Message Groups) of 5 messages to
RQST1
RQST2
RQST3
RQST4
RQST5

Now when these messages comes to NT queue manager the correl-ID will look something like this.
X'D9D8E2E3F1......'
X'D9D8E2E3F2......'
X'D9D8E2E3F3......'
X'D9D8E2E3F4......'
X'D9D8E2E3F5......'

Your "conversion" module will convert these values from EBCDIC to ASCII. After conversion these values will look like this,
X'5251535431.......'
X'5251535432.......'
X'5251535433.......'
X'5251535434.......'
X'5251535435.......'

With this you are still retaining the Correlation info.
We use this method of conversion all the time in the Broker and it's working fine.
_________________
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
Display posts from previous:   
Post new topic  Reply to topic Page 1 of 1

MQSeries.net Forum Index » IBM MQ API Support » Conversion of Msgid and Correlid
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.