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 » Message truncated in VB

Post new topic  Reply to topic
 Message truncated in VB « View previous topic :: View next topic » 
Author Message
sk
PostPosted: Thu Oct 18, 2001 11:09 am    Post subject: Reply with quote

Newbie

Joined: 30 Sep 2001
Posts: 3

Version of MQ used is 5.2. I am running the MQSeries Server on Windows NT and the MQSeries Client is on Windows 2000 Professional. The Client and the Server is on a different Machine. I am using MQSeries Automation Classes for ActiveX reference. I wrote a program in Visual Basic 6.0 which is putting a message on a request queue and I am getting back a message from the reply queue. The message which i am getting back from the reply queue is getting truncated. How can get back a message without being truncated. Is there any parameter that i should set. Thanks
Back to top
View user's profile Send private message
kolban
PostPosted: Thu Oct 18, 2001 11:43 am    Post subject: Reply with quote

Grand Master

Joined: 22 May 2001
Posts: 1072
Location: Fort Worth, TX, USA

How do you know the message is being truncated? What is the expected length of the message? What are you receiving? What are the values of the MessageLength and TotalMessageLength properties of the message? How is the get() method ot the MQQueue object used, what paramaters? If you disable the get, and use MQExplorer or MQJExplorer, what is the length of the message as reported by MQSeries?
Back to top
View user's profile Send private message
bower5932
PostPosted: Fri Oct 19, 2001 2:22 pm    Post subject: Reply with quote

Jedi Knight

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

I had somebody else report the same problem. They were displaying the message in a VB message box. The message box was doing the truncation. You can check the message by using the amqsbcg sample to see what is really on the queue.
Back to top
View user's profile Send private message Send e-mail Visit poster's website AIM Address Yahoo Messenger
mjung
PostPosted: Mon Dec 17, 2001 11:02 am    Post subject: Reply with quote

Newbie

Joined: 12 Nov 2001
Posts: 8
Location: Merrill Lynch

VB uses BSTR construct in dealing with Strings. BSTR can contain nulls and if you put the message on the queue and do not specify the message as binary then the message will probably get truncated if the message contains a null value in it.
Back to top
View user's profile Send private message Send e-mail
Wjbyczek
PostPosted: Fri Nov 22, 2002 8:37 am    Post subject: Reply with quote

Newbie

Joined: 08 May 2002
Posts: 4
Location: Domain Systemix

One other possibility is that the constant definition for your receive buffer size is too small to contain the entire message. If you're using the MQ VB samples, the buffer is, I believe, preconfigured to be 1000 characters. any message received that is longer than that will be truncated. Find the definition for the Buffer size in the include file and increase it for your project. I've found that's usually the most common problem with what appears to be truncation.
Back to top
View user's profile Send private message Send e-mail Visit poster's website Yahoo Messenger
PeterPotkay
PostPosted: Mon Nov 25, 2002 7:09 pm    Post subject: Reply with quote

Poobah

Joined: 15 May 2001
Posts: 7722

Make sure that you don't ask for accept truncated messages on the MQGMO options.

If you don't, the default is not to accept them. What I have seen is that then the buffer size you ask for makes no diff. I ask for a buffer of 1 byte, and the message is returned off of the queue each and every time no matter how big it is. I guess that MQAX200 under the covers does a second MQGET and your app gets the message with no error.
_________________
Peter Potkay
Keep Calm and MQ On
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 API Support » Message truncated in VB
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.