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 » IBM MQ Java / JMS » JMS Selectors and SQL syntax

Post new topic  Reply to topic
 JMS Selectors and SQL syntax « View previous topic :: View next topic » 
Author Message
JohnRodey
PostPosted: Mon Oct 01, 2007 12:27 pm    Post subject: JMS Selectors and SQL syntax Reply with quote

Centurion

Joined: 13 Apr 2005
Posts: 103

Since JMS selectors are based on SQL92 is there a package/class that you can load a selection string into and use getters/setters to modify?

For instance say I had a selector of MyRequestorName='Bob' AND MyRequestorID='1234'. Is there a package out there that will allow me to load that string into the constructor and let me call something to the effect of getFilterFields(), which would return MyRequestorName and MyRequestorID?

I am basically looking for a sql parser that can tell the difference between fields, conditions(AND,OR,NOT) and values.
Back to top
View user's profile Send private message
fjb_saper
PostPosted: Mon Oct 01, 2007 2:09 pm    Post subject: Reply with quote

Grand High Poobah

Joined: 18 Nov 2003
Posts: 20756
Location: LI,NY

A JMS message is not a DB table.
Be careful what you wish for, and grateful about what you are being offered.

Read more about JMS, Selectors and the performance caveats....

This seems to be more suited to a broker than a JMS selector...

Enjoy
_________________
MQ & Broker admin
Back to top
View user's profile Send private message Send e-mail
jefflowrey
PostPosted: Mon Oct 01, 2007 2:10 pm    Post subject: Reply with quote

Grand Poobah

Joined: 16 Oct 2002
Posts: 19981

Of course you'd need Message Broker to make this viable as a subscription option. The built in MQ pub/sub broker won't filter on content and neither will Event Broker.
_________________
I am *not* the model of the modern major general.
Back to top
View user's profile Send private message
JohnRodey
PostPosted: Mon Oct 01, 2007 2:26 pm    Post subject: Reply with quote

Centurion

Joined: 13 Apr 2005
Posts: 103

The question I'm asking is more of a straight JMS question, not necessarily a WebSphere MQ JMS question. And I am not writting a query. But the JMS Spec says that selectors are based off of SQL92 syntax. So is there a helper class that you knwo of that will return to me only the fields from my sql string. Kind of like XmlBeans treat an XML string like an object, I want to be able to treat a SQL string like one.

Any ideas?
Back to top
View user's profile Send private message
jefflowrey
PostPosted: Mon Oct 01, 2007 2:36 pm    Post subject: Reply with quote

Grand Poobah

Joined: 16 Oct 2002
Posts: 19981

I'm not aware of any general purpose SQL syntax tokenizer. Or something to marshal/unmarshall SQL into java objects. It's not clear at all that there's anything nearly as deterministic about SQL<->Java as there is XML<->Java..

XML tends to describe data. SQL tends to describe, umm, not data.
_________________
I am *not* the model of the modern major general.
Back to top
View user's profile Send private message
fjb_saper
PostPosted: Mon Oct 01, 2007 2:41 pm    Post subject: Reply with quote

Grand High Poobah

Joined: 18 Nov 2003
Posts: 20756
Location: LI,NY

And remember that the Message Selector (JMS) only works on the message's properties not on the message content...

Enjoy
_________________
MQ & Broker admin
Back to top
View user's profile Send private message Send e-mail
Display posts from previous:   
Post new topic  Reply to topic Page 1 of 1

MQSeries.net Forum Index » IBM MQ Java / JMS » JMS Selectors and SQL syntax
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.