Author |
Message
|
team |
Posted: Mon Nov 06, 2006 9:32 pm Post subject: selecting a mesage from a queue based on body content |
|
|
Centurion
Joined: 03 Nov 2006 Posts: 108
|
Hi
I want to select one message from a queue based on the value in one of its tag in its message body.
I do not want to select a message based on its msgid and correlid.
Please advise.
Thanks,
Team. |
|
Back to top |
|
 |
Vitor |
Posted: Tue Nov 07, 2006 1:48 am Post subject: |
|
|
 Grand High Poobah
Joined: 11 Nov 2005 Posts: 26093 Location: Texas, USA
|
At first glance, you can't. WMQ is a messaging system not a database.
At second glance, why would you want to - see above.
At third glance, you shouldn't try - it's not exactly best practice.
Perhaps if you explained a little more what you're trying to achieve, we might be able to expound a solution. A little more detail along the lines of message format, platform, broker level, MQ level, etc could help too.
The more you can help us, the more we can help you.  _________________ Honesty is the best policy.
Insanity is the best defence. |
|
Back to top |
|
 |
team |
Posted: Tue Nov 07, 2006 3:45 am Post subject: |
|
|
Centurion
Joined: 03 Nov 2006 Posts: 108
|
Thanks a lot for your quick response.
We are using Websphere MQ 6.0, WBIMB 6.0
The requirement is to pick up only a few messages which satisfy some data condition in the message body.
The messages are all dumped in a queue by some other application. We are trying to find out if some particular messages can be selected from the queue (based on data condition) itself, rather than dumping all the messages in the database first and then selecting the ones we need.
Thanks,
Team. |
|
Back to top |
|
 |
gbbailey |
Posted: Tue Nov 07, 2006 3:50 am Post subject: |
|
|
 Apprentice
Joined: 12 May 2006 Posts: 27 Location: London, UK
|
What would you want to happen to messages that don't satisfy the data condition?
From what I understand from your requirements, you can pick up al lthe messages in WBIMB and only insert those that meet the requirement into your database. What you do with the messages after that is up to you - throw them away or put them back on the original queue or onto another queue or whatever. |
|
Back to top |
|
 |
jefflowrey |
Posted: Tue Nov 07, 2006 4:29 am Post subject: |
|
|
Grand Poobah
Joined: 16 Oct 2002 Posts: 19981
|
Maybe you should have the dumping application use Pub/Sub.
Then you can create a flow that will subscribe to those messages - and include a content filter to match your data condition. _________________ I am *not* the model of the modern major general. |
|
Back to top |
|
 |
jbanoop |
Posted: Wed Nov 08, 2006 12:25 am Post subject: |
|
|
Chevalier
Joined: 17 Sep 2005 Posts: 401 Location: SC
|
or have an initial flow which would pick all the requests, check for the data and depending on that route the messages to different queue(s).
your flow that inserts into the db can listen on the queue where the messages which satisfy the condition land up.
Hope it helps.
Regards,
Anoop |
|
Back to top |
|
 |
|