Hi all, I have designed a web based application using jsp,servlets & database as oracle.Now i want to have a search engine that can access tables in my database and retrieve the records.For example the user may perform search using name,emailid,phone number etc. Please suggest how to proceed.
Well, I think Lucene is for searching the pages, not the database.
But you could create a Form to take the users criteria, call a Servlet passing that criteria and the table to search on, and have a general Object that takes that information creates an SQL query and use JDBC.
Now, that is the down and dirty way, there are frameworks for this type of application, like Struts, AJAX (to do the search without refreshing the apge, if you need that), JSF, Ruby on Rails.
You could use Lucene to "index" anything. With the API you feed it one "document" at a time. You could retrieve each database record, make a document, index it with its primary key and then use Lucene to search and get back the key. It doesn't sound real slick though; duplication of database data in an external index that you have to keep in sync doesn't feel right.
If you can get by with the database queries described above it would be a lot cleaner.
A good question is never answered. It is not a bolt to be tightened into place but a seed to be planted and to bear more seed toward the hope of greening the landscape of the idea. John Ciardi
I’ve looked at a lot of different solutions, and in my humble opinion Aspose is the way to go. Here’s the link: http://aspose.com