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 » How to get Message by Index

Post new topic  Reply to topic
 How to get Message by Index « View previous topic :: View next topic » 
Author Message
Le_Quang_Hoa
PostPosted: Tue Jun 07, 2005 2:16 am    Post subject: How to get Message by Index Reply with quote

Apprentice

Joined: 14 May 2005
Posts: 29
Location: Viet nam

Dear all

I want to get each message from queue by index
I write by ASP. net but I don't know how to get it

Thanks
_________________
Le Quang Hoa (Mr)
Email :hoa.lequang@gmail.com
YM: hoalq98
Ha noi City - Viet Nam
Back to top
View user's profile Send private message Send e-mail Yahoo Messenger
jefflowrey
PostPosted: Tue Jun 07, 2005 3:36 am    Post subject: Reply with quote

Grand Poobah

Joined: 16 Oct 2002
Posts: 19981

What index?
_________________
I am *not* the model of the modern major general.
Back to top
View user's profile Send private message
Le_Quang_Hoa
PostPosted: Tue Jun 07, 2005 5:22 am    Post subject: Reply with quote

Apprentice

Joined: 14 May 2005
Posts: 29
Location: Viet nam

Dear ,
for ex: my queue has 10 Message
I want to get message 7th in this queue

How I can do it with ASP Net
_________________
Le Quang Hoa (Mr)
Email :hoa.lequang@gmail.com
YM: hoalq98
Ha noi City - Viet Nam
Back to top
View user's profile Send private message Send e-mail Yahoo Messenger
Nigelg
PostPosted: Tue Jun 07, 2005 5:52 am    Post subject: Reply with quote

Grand Master

Joined: 02 Aug 2004
Posts: 1046

There is no option to get the 7th msg directly.

You could browse the queue with lock and count the msgs. When you get to the 7th msg, get the msg under the cursor.

Alternatively, browse all the msgs and save the MsgId. Then get by MsgId the msg you want.
Back to top
View user's profile Send private message
jefflowrey
PostPosted: Tue Jun 07, 2005 5:54 am    Post subject: Reply with quote

Grand Poobah

Joined: 16 Oct 2002
Posts: 19981

Why do you want to do this?

It is pretty much trying to treat a queue as a database. And a queue is not a database?

What are you trying to accomplish by doing this?
_________________
I am *not* the model of the modern major general.
Back to top
View user's profile Send private message
Le_Quang_Hoa
PostPosted: Tue Jun 07, 2005 6:07 pm    Post subject: Reply with quote

Apprentice

Joined: 14 May 2005
Posts: 29
Location: Viet nam

Thank for reply

My app do :
I want to sure that each message was input into Database before I clear it?

How I can get Message by MessageID?
any one have code
Thanks
_________________
Le Quang Hoa (Mr)
Email :hoa.lequang@gmail.com
YM: hoalq98
Ha noi City - Viet Nam
Back to top
View user's profile Send private message Send e-mail Yahoo Messenger
jefflowrey
PostPosted: Wed Jun 08, 2005 3:15 am    Post subject: Reply with quote

Grand Poobah

Joined: 16 Oct 2002
Posts: 19981

Le_Quang_Hoa wrote:
I want to sure that each message was input into Database before I clear it?


Then you want to use a coordinated transaction, not anything else.

This is also known as two-phase commit, or XA.

There are samples on the IBM page at http://www.developer.ibm.com/isv/tech/sampmq.html that will help you at least some.
_________________
I am *not* the model of the modern major general.
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 » General IBM MQ Support » How to get Message by Index
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.