lucene-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Erik Hatcher <>
Subject Re: Lucene vs SQL database
Date Thu, 29 Sep 2005 12:56:50 GMT

On Sep 29, 2005, at 8:46 AM, Eugeny N Dzhurinsky wrote:
> On Thu, Sep 29, 2005 at 08:39:53AM -0400, George Abraham wrote:
>> Eugene,
>> You could grab all the fields for a record in a SQL database, mash  
>> it all
>> together and transfer it into one indexing field in Lucene. Use some
>> scripting tools (or even JDBC and Java) to do this. However if you  
>> are
>> asking if Lucene can go and look over a SQL database and return  
>> results,
>> that would not work. Lucene has to index the database fields  
>> first. The
>> indexing would happen with the first two sentences of my post.
> Integersting. We have some kind of set of privileges, required to  
> access the
> object (let's say rows in table(s)), I thought if it is possible to  
> use
> kind of "injection" of access control statement to SQL query for  
> extraction
> of only allowed data... But if Lucene needs to index anything, how  
> could I
> define the access privileges for data?

There are many options available.  One such technique I described in  
"Lucene in Action" ... a SecurityFilter.  This simple example scheme  
assumes each document has an "owner" and only owners are allowed to  
see their documents and no others.  By applying a SecurityFilter on a  
search, the results are constrained appropriately.  This scheme is  
intentionally simplistic to show the possibilities.  More commonly  
would be a situation with users and groups that need to be  
dynamically configurable - a Filter could still do this sort of  
thing, but how documents are associated with groups would need to be  
thoroughly conceived.


To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message