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 » MQ Client for Windows get/put .tif files

Post new topic  Reply to topic
 MQ Client for Windows get/put .tif files « View previous topic :: View next topic » 
Author Message
ipmqadm
PostPosted: Wed Apr 18, 2007 1:34 pm    Post subject: MQ Client for Windows get/put .tif files Reply with quote

Acolyte

Joined: 18 Apr 2007
Posts: 68

I am attempting to send and receive TIFF images via an MQ 6.0 client on Windows. The supplied amqsputc and amqsgetc commands don't seem to work. I have been told (unofficialy) that the amqsputc and amqsgetc commands only work on ascii text files.

We also had to recompile the C source code for the 2 commands to increase the bufferspace which was set at 100 bytes.

Has ANYONE sent .tif images via an MQ client? If so how were you able to put/get the images across the serverconn?

Thanks for any assistance you experts can provide.
Back to top
View user's profile Send private message
jefflowrey
PostPosted: Wed Apr 18, 2007 1:46 pm    Post subject: Reply with quote

Grand Poobah

Joined: 16 Oct 2002
Posts: 19981

MQ treats the message buffer as a stream of bytes. As such, for the most part it does not care what the contents of the buffer are.

However, if you instruct MQ that the message buffer is character data, and you ask MQ to convert the data, either when you pass it across a channel or when you get it from the queue, then it will treat the message buffer as character data and perform character translation.

What this all means is that you need to change the line in the PUT program that assigns MQFMT_STRING to MQMD.Format, so that it assigns MQFMT_NONE instead.
_________________
I am *not* the model of the modern major general.
Back to top
View user's profile Send private message
ipmqadm
PostPosted: Wed Apr 18, 2007 2:00 pm    Post subject: Reply with quote

Acolyte

Joined: 18 Apr 2007
Posts: 68

Thanks Jeff.

I'm assuming that the same will apply to the get command program as well. I will examine the source to the put command and the get command.

My ultimate goal is to be able to use the supplied amqsgetc and amqsputc commands to do the transfers instead of having to create some C or Java or .Net applications to do the transfers.

Your hint may help me.

Thanks...
Back to top
View user's profile Send private message
jefflowrey
PostPosted: Wed Apr 18, 2007 2:02 pm    Post subject: Reply with quote

Grand Poobah

Joined: 16 Oct 2002
Posts: 19981

You don't really need to touch the get program.

And you could look at the File Transfer Application that come with v6, as well...

http://publib.boulder.ibm.com/infocenter/wmqv6/v6r0/topic/com.ibm.mq.amqzag.doc/fa22360_.htm
_________________
I am *not* the model of the modern major general.
Back to top
View user's profile Send private message
ipmqadm
PostPosted: Wed Apr 18, 2007 3:04 pm    Post subject: Reply with quote

Acolyte

Joined: 18 Apr 2007
Posts: 68

Jeff,

I can't find the download for the File Transfer Application for the client or the server. Can you find it?
Back to top
View user's profile Send private message
jefflowrey
PostPosted: Wed Apr 18, 2007 3:48 pm    Post subject: Reply with quote

Grand Poobah

Joined: 16 Oct 2002
Posts: 19981

It's either already installed, or you need to do a custom install from your original media.
_________________
I am *not* the model of the modern major general.
Back to top
View user's profile Send private message
ipmqadm
PostPosted: Wed Apr 18, 2007 6:28 pm    Post subject: Reply with quote

Acolyte

Joined: 18 Apr 2007
Posts: 68

Thanks.
Back to top
View user's profile Send private message
marcin.kasinski
PostPosted: Wed Apr 18, 2007 11:06 pm    Post subject: Reply with quote

Sentinel

Joined: 21 Dec 2004
Posts: 850
Location: Poland / Warsaw

When I had to send file via MQ from my code I converted file to base64 data.

Code:
      Base64 base = new Base64();
      byte[] base64value = base.encode(readbytes);
      String base64content= new String( base64value, "UTF-8" );

      System.out.println(fileName+" length:"+content.length());
                  this.sendMQ(queueOut,"<DATA><FILENAME>"+fileName+"</FILENAME><BASE64CONTENT><![CDATA["+base64content+"]]></BASE64CONTENT></DATA>");



What do you think about it ?
Is it a good idea ?


+ I can send additional info in one message
- data lrngth
_________________
Marcin
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 » General IBM MQ Support » MQ Client for Windows get/put .tif files
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.