Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » EclipseLink » JAPA search query on DB
JAPA search query on DB [message #493652] Tue, 27 October 2009 13:33 Go to next message
Enrico is currently offline EnricoFriend
Messages: 82
Registered: July 2009
Member
Dear All,

I would like to implement a query that search on a set of table for all
records that have some keyword on their field.
This query must implement the "simple search" function by keywords on a
website (I mean...user insert a keyword in the search box and all the
entities in the Db with a coloumn hat contains that keywords must return).

I would like to know what is the best way to implement the search on a
webisite db (or a subset of tables) or if there is already some
eclipselink facility to get that.

BR,
Enrico
Re: JAPA search query on DB [message #494174 is a reply to message #493652] Thu, 29 October 2009 13:23 Go to previous message
James Sutherland is currently offline James SutherlandFriend
Messages: 1939
Registered: July 2009
Location: Ottawa, Canada
Senior Member

Are you trying to query a single class, or multiple classes?

If you are trying to query multiple class, you may need to query them one by one based on your model.

One possibility may be to use EclipseLink's interface descriptor support if all of your class share a common interface. Then you could perform a single conceptual query, and EclipseLink would query each table. JPA does not support interfaces, so you would need to define the interface descriptors using a SessionCustomizer and the EclipseLink descriptor code API.



James : Wiki : Book : Blog : Twitter
Previous Topic:Mapping of Collection of Base class objects
Next Topic:Cache coordination
Goto Forum:
  


Current Time: Thu Apr 25 20:28:36 GMT 2024

Powered by FUDForum. Page generated in 0.02658 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top