You are viewing a plain text version of this content. The canonical link for it is here.
Posted to java-user@lucene.apache.org by Sean LeBlanc <se...@nutros.com> on 2002/02/09 00:08:54 UTC
New to Lucene
Hi,
I was reading over the docs and reading up in general on Lucene. I want to
know if I can do the following:
1. Select one column from a subset of tables in a MS SQL Server database I
have, and index those...with some mechanism to keep the index in sync with
data as rows are added.
2. Run a query against one or many of the index columns.
Is this possible? I see that Lucene *can* index database data, but something
needs to be coded to handle this? Has anyone built any thin framework or
have code snippets available? Has anyone ever used Lucene to replace
Fulcrum?
TIA,
Sean
--
To unsubscribe, e-mail: <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>
RE: New to Lucene
Posted by Sean LeBlanc <se...@nutros.com>.
> -----Original Message-----
> From: Andrew C. Oliver [mailto:acoliver@apache.org]
> Sent: Saturday, February 09, 2002 5:55 AM
> To: Lucene Users List
> Subject: Re: New to Lucene
>
>
> Why not just have the DBA add an index to those fields and do it with
> SQL?
>
> -Andy
Unfortunately, it's not nearly so simple. If I understand correctly, Lucene
provides cababilities for searching on text that go beyond what one can
(easily and quickly) do with SQL. If you have an 8000 character column for
example, and you are searching for a *word* that begins with, say, the
letters
"ch", I can't just use a where clause that says "...where mycol like
'%ch%'".
> On Fri, 2002-02-08 at 18:08, Sean LeBlanc wrote:
> > Hi,
> >
> > I was reading over the docs and reading up in general on
> Lucene. I want to
> > know if I can do the following:
> >
> > 1. Select one column from a subset of tables in a MS SQL
> Server database I
> > have, and index those...with some mechanism to keep the
> index in sync with
> > data as rows are added.
> > 2. Run a query against one or many of the index columns.
> >
> > Is this possible? I see that Lucene *can* index database
> data, but something
> > needs to be coded to handle this? Has anyone built any thin
> framework or
> > have code snippets available? Has anyone ever used Lucene to replace
> > Fulcrum?
> >
> >
> > TIA,
> > Sean
--
To unsubscribe, e-mail: <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>
Re: New to Lucene
Posted by "Andrew C. Oliver" <ac...@apache.org>.
Why not just have the DBA add an index to those fields and do it with
SQL?
-Andy
On Fri, 2002-02-08 at 18:08, Sean LeBlanc wrote:
> Hi,
>
> I was reading over the docs and reading up in general on Lucene. I want to
> know if I can do the following:
>
> 1. Select one column from a subset of tables in a MS SQL Server database I
> have, and index those...with some mechanism to keep the index in sync with
> data as rows are added.
> 2. Run a query against one or many of the index columns.
>
> Is this possible? I see that Lucene *can* index database data, but something
> needs to be coded to handle this? Has anyone built any thin framework or
> have code snippets available? Has anyone ever used Lucene to replace
> Fulcrum?
>
>
> TIA,
> Sean
>
>
> --
> To unsubscribe, e-mail: <ma...@jakarta.apache.org>
> For additional commands, e-mail: <ma...@jakarta.apache.org>
>
--
www.superlinksoftware.com
www.sourceforge.net/projects/poi - port of Excel format to java
http://developer.java.sun.com/developer/bugParade/bugs/4487555.html
- fix java generics!
The avalanche has already started. It is too late for the pebbles to
vote.
-Ambassador Kosh
--
To unsubscribe, e-mail: <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>
Re: New to Lucene
Posted by Kelvin Tan <ke...@relevanz.com>.
----- Original Message -----
From: Ype Kingma <yk...@xs4all.nl>
To: Lucene Users List <lu...@jakarta.apache.org>
Sent: Saturday, February 09, 2002 4:48 PM
Subject: Re: New to Lucene
[snip]
> >Is this possible? I see that Lucene *can* index database data, but
something
> >needs to be coded to handle this? Has anyone built any thin framework or
> >have code snippets available? Has anyone ever used Lucene to replace
> >Fulcrum?
>
> Not me, perhaps someone else.
>
>
Just posted some code on lucene-dev which may be related to what you're
looking for.
Regards,
Kelvin
--
To unsubscribe, e-mail: <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>
Re: New to Lucene
Posted by Ype Kingma <yk...@xs4all.nl>.
Sean,
>Hi,
>
>I was reading over the docs and reading up in general on Lucene. I want to
>know if I can do the following:
>
>1. Select one column from a subset of tables in a MS SQL Server database I
>have, and index those...with some mechanism to keep the index in sync with
>data as rows are added.
You'll need the following:
- a design for your lucene documents, ie. which fields are you going to use,
- a program to walk each of the tables, create lucene documents from the rows,
and add these documents to your lucene db(s). You'll have to choose a lucene
field to use as primary key in the lucene db(s). There has been quite a bit
of discussion lately on how to add documents to a lucene db, check the
archives. Note that lucene itself has no facilities for primary keys.
Basically you'll have to batch document additions: delete an evt. set
of documents to be replaced and then add a set of new documents.
>2. Run a query against one or many of the index columns.
You can query each lucene field seperately. Have a look at the query
language, because this might well influence the design of your documents.
>Is this possible? I see that Lucene *can* index database data, but something
>needs to be coded to handle this? Has anyone built any thin framework or
>have code snippets available? Has anyone ever used Lucene to replace
>Fulcrum?
Not me, perhaps someone else.
>
>TIA,
My pleasure,
Ype
P.S. I can recommend to use Jython for the importing part.
There is always a bit of experimenting needed, so a scripting language is ideal.
Also most of the time will be spent within the Lucene API, leaving
the scripting overhead negligable.
--
--
To unsubscribe, e-mail: <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>