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 » General IBM MQ Support » Can we use "{}" in the MQMD - Message ID

Post new topic  Reply to topic
 Can we use "{}" in the MQMD - Message ID « View previous topic :: View next topic » 
Author Message
raghav
PostPosted: Wed Jun 15, 2005 10:43 am    Post subject: Can we use "{}" in the MQMD - Message ID Reply with quote

Novice

Joined: 15 Apr 2005
Posts: 24

Is it possible to use special characters such as '"{}: when setting the Message ID..?
For example:
MQMD.MsgId = "{0123:ABC**********}";
Back to top
View user's profile Send private message
jefflowrey
PostPosted: Wed Jun 15, 2005 10:46 am    Post subject: Reply with quote

Grand Poobah

Joined: 16 Oct 2002
Posts: 19981

You can use binary zero when setting a message ID - it's a byte array.

But you shouldn't set a message ID.

Treating a queue like a database is an antipattern.
_________________
I am *not* the model of the modern major general.
Back to top
View user's profile Send private message
raghav
PostPosted: Wed Jun 15, 2005 3:59 pm    Post subject: Reply with quote

Novice

Joined: 15 Apr 2005
Posts: 24

Can we provide a pattern to the Message ID?

For example, setting the first 4-5 bytes as:

char pattern[24] ;
strcpy(pattern, "{AMQ}");

convert field pattern into a byte string and assign it to MQMD.MsgId.

Is it advisible to do this..?
Back to top
View user's profile Send private message
wschutz
PostPosted: Wed Jun 15, 2005 4:18 pm    Post subject: Reply with quote

Jedi Knight

Joined: 02 Jun 2005
Posts: 3316
Location: IBM (retired)

You CAN do strcpy(MQMD.MsgID, "{0123:ABC**********}"); and that will certainly work. But be aware, that MQ will not translate the MsgId (nor the CorrelID) fields, so if you ae sending the message from an ASCII to EBCDIC platform, it will not be converted for you.

Why do you want to do this? Perhaps if you told us what you're trying to accomplish, a better solution can be suggested.

-w
Back to top
View user's profile Send private message Send e-mail AIM Address
Display posts from previous:   
Post new topic  Reply to topic Page 1 of 1

MQSeries.net Forum Index » General IBM MQ Support » Can we use "{}" in the MQMD - Message ID
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.