Win a copy of Functional Reactive Programming this week in the Other Languages forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Lucene and google-type search functionality

 
Lorenz Baylon
Ranch Hand
Posts: 99
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Guys,

I am looking for a an open source tool for java application which can do some of google's search functionality such as fuzzy searching, ranking, etc, but will look into rdbms records (or indexed records from rdbms) and not from a text-based index. Can lucene help me with this?

Thanks in advance guys!

Regards,

Lhorenz
 
Ulf Dittmer
Rancher
Posts: 42968
73
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
The index is created by code you write, so if your code looks at database records instead if text files, then that is no problem.

The index itself will always consist of text files, though (unless it is small enough that you can consider keeping it in memory), but that shouldn't be an issue.

From the Lucene FAQ:
How can I use Lucene to index a database?

Connect to the database using JDBC and use an SQL "SELECT" statement to query the database. Then create one Lucene Document object per row and add it to the index. You will probably want to store the ID column so you can later access the matching items. For other (text) columns it might make more sense to only index (not store) them, as the original data is still available in your database.
 
Lorenz Baylon
Ranch Hand
Posts: 99
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks a lot Ulf! You've been helpful and patient
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic