Beefy Boxes and Bandwidth Generously Provided by pair Networks
XP is just a number
 
PerlMonks  

Browse message from MQSeries queue using perl API for MQSeries(WMQ)

by sselva (Novice)
on Jan 26, 2012 at 20:05 UTC ( #950211=perlquestion: print w/ replies, xml ) Need Help??
sselva has asked for the wisdom of the Perl Monks concerning the following question:

Hi Monks ,

I got request to display message from MQSeries queue with non-destructive manner using perl . I tried to get some clues from google but no luck as of now , after long try I am posting this

I tried with MQOO_BROWSE without MQOO_INPUT_* options while initialize the queue and used MQGMO_BROWSE_* options while access the queue . But script reads message in destructive manner .

any clues which option I should use here to overcome from this

Comment on Browse message from MQSeries queue using perl API for MQSeries(WMQ)
Re: Browse message from MQSeries queue using perl API for MQSeries(WMQ)
by Anonymous Monk on Jan 27, 2012 at 09:16 UTC
      Hi ,

      I tried with below code snippet while get message (MQGET) from queue

      my $mh = MQSeries::Message->new ( MsgDesc => { CodedCharSetId => 1208}, Options => (MQGMO_BROWSE_FIRST), BufferLength => 16 * 1024 * 1024 ) ;

      and queue initialize (MQ OPEN) code snippet

      $inqh = MQSeries::Queue->new ( QueueManager => $qmh, Queue => "QL.TEST", Options => (MQOO_BROWSE|), )

      here I tried with both MQOO_INPUT_* as well . While tried with MQOO_BROWSE option I am getting 2037 error " Queue not opend for input" , but when I tried with MQOO_INPUT_* its getting message with destructive manner .

      I have checked the below link and they recommend to use MQOO_BROWSE :http://publibz.boulder.ibm.com/cgi-bin/bookmgr_OS390/BOOKS/CSQZAL05/2.5.10?SHELF=AMQZA90E&DT=20001013121047&CASE=

      but its not working :(

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: perlquestion [id://950211]
Approved by planetscape
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others making s'mores by the fire in the courtyard of the Monastery: (7)
As of 2014-09-21 10:11 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    How do you remember the number of days in each month?











    Results (168 votes), past polls