Search...
FAQs
Subscribe
Pie
FAQs
Recent topics
Flagged topics
Hot topics
Best topics
Search...
Search within WebSphere
Search Coderanch
Advance search
Google search
Register / Login
Post Reply
Bookmark Topic
Watch Topic
New Topic
programming forums
Java
Mobile
Certification
Databases
Caching
Books
Engineering
Micro Controllers
OS
Languages
Paradigms
IDEs
Build Tools
Frameworks
Application Servers
Open Source
This Site
Careers
Other
Pie Elite
all forums
this forum made possible by our volunteer staff, including ...
Marshals:
Campbell Ritchie
Jeanne Boyarsky
Ron McLeod
Paul Clapham
Liutauras Vilda
Sheriffs:
paul wheaton
Rob Spoor
Devaka Cooray
Saloon Keepers:
Stephan van Hulst
Tim Holloway
Carey Brown
Frits Walraven
Tim Moores
Bartenders:
Mikalai Zaikin
Forum:
WebSphere
Help to create MQ message in java
Mario Gimenez
Ranch Hand
Posts: 38
posted 13 years ago
Number of slices to send:
Optional 'thank-you' note:
Send
Hi
I need some example for create a message to send via MQ Websphere in
java
.
I create and send a message but I need put some kind of format because the message arrive wrong in mq. I don't know do that.
Sorry for my english.
Ernesto Chicas
Greenhorn
Posts: 18
I like...
posted 13 years ago
Number of slices to send:
Optional 'thank-you' note:
Send
I understand that your problem is with the format of the message and not sending the message to an MQ queue, you can try the following:
MQMessage mqMessage = new MQMessage(); MQPutMessageOptions pmo = new MQPutMessageOptions(); pmo.options = MQC.MQOO_SET_IDENTITY_CONTEXT; //what you need mqMessage.persistence = MQC.MQPER_PERSISTENT; //format is MQC.MQFMT mqMessage.format = MQC.MQFMT_STRING; mqMessage.expiry = MQC.MQEI_UNLIMITED; mqMessage.messageId = MQC.MQMI_NONE; mqMessage.messageType = MQC.MQMT_DATAGRAM; //what you need // put the message in MQQueue mqQueue.put(mqMessage,pmo);
if it fails, you can put your source code and review
The MQC class is deprecated in WMQ v7, but should work.
Anton Novopashin
Greenhorn
Posts: 19
posted 10 years ago
Number of slices to send:
Optional 'thank-you' note:
Send
Yo can use
Deprecation list
MQC constants have moved to MQConstants class, see
MQConstants class
OCJP (1Z0-851).
Integration Developer (000-607).
WAS Admin (000-377).
reply
reply
Bookmark Topic
Watch Topic
New Topic
Boost this thread!
Similar Threads
MQ series
Getting Started - Java MQ Connection - Please help!
Can we send a file to MQ
SOAP JMS
How to put and retrive data from MQ using Java
More...