Re: Problem with Field.Text()

2006-10-05 Thread Jan Pieper
Yeah it works :) thanks to all, for help. You have to create a new Field class with "new Field(...", i.e. replace doc.add(Field.Text with doc.add(new Field(... Antony Jan Pieper wrote: No it is not your fault, it is mine, but it also does not function. My compiler gives me this err

Re: ask for a question about Lucene

2006-10-05 Thread Chris Lu
You can use DBSight. It's free for your data. And you just need to follow this example you will know how to use it, no java coding needed. And you can schedule jobs to synchronize with the database. http://wiki.dbsight.com/index.php?title=Step_by_step The website is: http://www.dbsight.net Chri

Re: Advantage of putting lucene index in RDBMS

2006-10-05 Thread Mag Gam
I appreciate everyone's responses. I guess the main advantage of putting lucene's index into a RDBMS is for flexibility of queries. Personally, I rather use a RDBMS for results than lucene because I am more experienced with SQL queries than using Java. Does anyone have a simple example of using

Re: Find if words are in the same phrase?

2006-10-05 Thread Michael Imbeault
Thanks Chris, your answers were very insightful as always, this is exactly what i was asking for. Posting at 2 AM, I should stop doing that, I write in a confusing manner :) Michael Imbeault CHUL Research Center (CHUQ) 2705 boul. Laurier Ste-Foy, QC, Canada, G1V 4G2 Tel: (418) 654-2705, Fax: (4

Re: ask for a question about Lucene

2006-10-05 Thread Erick Erickson
My gut feel is that, with 150 records, using Lucene is overkill. This assumes that your database already exists. You'd have to extract the data from the DB, store it in a lucene index, then worry about keeping them synchronized. I'd suggest, though, that the fastest way to satisfy yourself about

ask for a question about Lucene

2006-10-05 Thread lily yan
Hello ALL, i'm new to Lucene and wandering where i can start from Lucene? : ) basically my application is: when user input some keywords (can be more than one words) within an academic research site, the output will be the researchers' academic interests. there are will be a DB2 database tha

Re: Problem with Field.Text()

2006-10-05 Thread Erick Erickson
Is your classpath or buildpath for the project in Eclipse) pointing to 2.0rather than 1.x? Erick On 10/5/06, Steven Parkes <[EMAIL PROTECTED]> wrote: Do you have the appropriate imports? Look at IndexFiles.java in src/demo/org/apache/lucene/demo. It uses this call for adding two fields. You s

Re: Problem with Field.Text()

2006-10-05 Thread Antony Bowesman
You have to create a new Field class with "new Field(...", i.e. replace doc.add(Field.Text with doc.add(new Field(... Antony Jan Pieper wrote: No it is not your fault, it is mine, but it also does not function. My compiler gives me this error message: ---

RE: Problem with Field.Text()

2006-10-05 Thread Steven Parkes
Do you have the appropriate imports? Look at IndexFiles.java in src/demo/org/apache/lucene/demo. It uses this call for adding two fields. You should be able to build this with "ant compile-demo". That should help get you started. -Original Message- From: Jan Pieper [mailto:[EMAIL PROTECTE

Re: Problem with Field.Text()

2006-10-05 Thread Jan Pieper
No it is not your fault, it is mine, but it also does not function. My compiler gives me this error message: cannot find symbol: method Field( java.lang.String, java.lang.String, org.apache.lucene.document.

RE: Problem with Field.Text()

2006-10-05 Thread Steven Parkes
Blah. Sorry for the typo. Get rid of the .Text: Field(String, String, Field.Store.YES, Field.Index.TOKENIZED); -Original Message- From: Jan Pieper [mailto:[EMAIL PROTECTED] Sent: Thursday, October 05, 2006 2:53 PM To: java-user@lucene.apache.org Subject: Problem with Field.Text() I hope

Problem with Field.Text()

2006-10-05 Thread Jan Pieper
I hope now I am in the right mailinglist. In the -dev mailinglist Steven Parkes said, that I have to change this: > Field.Text(String, String); to > Field.Text(String, String, Field.Store.YES, Field.Index.TOKENIZED); But it seems that there isnt such a method declaration. Where is the mistake

Mutliple indexes or many small documents?

2006-10-05 Thread Joe Shaw
Hi, I'm in the process of moving away from Lucene-as-the-data-store to using Lucene solely for text indexing and storing a lot of (frequently changing) metadata in a database. At present, we have two indexes which we search. The primary index contains the static data -- data that changes only wh

Re: Different boost values for different terms in a field.

2006-10-05 Thread Doron Cohen
Frode Bjerkholt <[EMAIL PROTECTED]> wrote on 05/10/2006 01:10:43: > My intention is to give different terms in a field different boost values. > The queries from a use perspective, will be one fulltext input field. > The following code illustrates this: > > Field f1 = new Field("name", "John", Fiel

Re: Find if words are in the same phrase?

2006-10-05 Thread Chris Hostetter
1) search the list archives for: sentence paragraph and you'll find some discussions on generating position gaps in your analyzer to help esure that sloppy phrase queries are confined to a single sentence, or paragraph, or page. AND/OR using marker terms to denote the boundaries of various parts o

Re: discontinuous range query

2006-10-05 Thread Chris Hostetter
: It's clear that my problem here comes from a lack of understanding of : the semantics of SHOULD, MUST, and MUST_NOT. : : I haven't found a clear description of this (except for a brief : comment here : http://mail-archives.apache.org/mod_mbox/lucene-java-dev/200408.mbox/[EMAIL PROTECTED]). : Mo

Re: discontinuous range query

2006-10-05 Thread Doron Cohen
I sometimes find it helpful to think of the query parts as applying 'filtering' logic, helping to understand how query components play together in determining the acceptable set of results (mostly ignoring scoring here, which would usually sort the candidate results). Consider a set of 10 douments

Re: Sudden FileNotFoundException

2006-10-05 Thread Hes Siemelink
Yes, I use default settings. Cheers, Hes. On 10/5/06, Michael McCandless <[EMAIL PROTECTED]> wrote: Hes Siemelink wrote: > Not making much progress, but there is one thing I found curious: very > often > the file that can not be found is "_8km.fnm". > Is it possible to derive any informatio

Re: Sudden FileNotFoundException

2006-10-05 Thread Michael McCandless
Hes Siemelink wrote: Not making much progress, but there is one thing I found curious: very often the file that can not be found is "_8km.fnm". Is it possible to derive any information from this? Hmmm, that's interesting. Segment numbers are just integers encoded in base 36, ie, using the dig

Re: Advantage of putting lucene index in RDBMS

2006-10-05 Thread Aleksei Valikov
Hi. As one of the people who asked about placing indeces into RDBMS, I was primarily interested in just storing index in the RDBMS (basically, storing the structures described on this page http://lucene.apache.org/java/docs/fileformats.html in the relational DB). The main reason is NOT to be abl

Re: Sorting on dates using long

2006-10-05 Thread Yonik Seeley
On 10/5/06, Björn Ekengren <[EMAIL PROTECTED]> wrote: I am trying to get sort by date to work. The dates are of form MMddhhmm and it seems that sort sees them as Integers and discards the last four numbers since an integer isn't large enough. I tried using SortField.STRING instead but then

Re: Advantage of putting lucene index in RDBMS

2006-10-05 Thread Aleksei Valikov
Hi. I have been reading the lists for couple of week now, and I noticed people asking about placing their indexes into a RDBMS. What is the advantage of that? So far lucene was able to solve all my problems, but I am curious how else people are using it (especially with RDBMS). Having

RE: Advantage of putting lucene index in RDBMS

2006-10-05 Thread Paul Snyder
Re-reading Aleksei's post, I have to ask, is it really not possible/practical to index the database metadata (such as date, area and schema/table/primary-key info) as Lucene document fields? I am having difficulty conceiving a scenario when this would not be a practical option. -Original Mess

RE: Advantage of putting lucene index in RDBMS

2006-10-05 Thread Vladimir Olenin
As one of the people who asked about placing indeces into RDBMS, I was primarily interested in just storing index in the RDBMS (basically, storing the structures described on this page http://lucene.apache.org/java/docs/fileformats.html in the relational DB). The main reason is NOT to be able to pe

Sorting on dates using long

2006-10-05 Thread Björn Ekengren
Hello, I am trying to get sort by date to work. The dates are of form MMddhhmm and it seems that sort sees them as Integers and discards the last four numbers since an integer isn't large enough. I tried using SortField.STRING instead but then constantrangequery breaks (date:[200501010101 TO

RE: Advantage of putting lucene index in RDBMS

2006-10-05 Thread Paul Snyder
Aleksei, can you point me to a document detailing this procedure with examples? If not, would you consider creating one? I am particularly interested in what prerequisite steps are needed to perform a Lucene query within SQL (if I understand correctly what you are doing). -Original Message--

Re: sort ordering

2006-10-05 Thread Erick Erickson
Search the mail archives for "date" and "sort" and you'll get many, many responses. The short form is look at the DateTools class, and also look at the Sort class. Be aware that there are several issues regarding *ranges* of dates if you have a need to search over, say, "all dates from 20060101 t

sort ordering

2006-10-05 Thread Amit Soni
Hi all, I have been using Lucene from last few days. Right now i am reading some records from the db then convert in Document of lucene and then adds that document in lucene index. But in my record i have one field which is created_date and i want to search for given query in created_date ord

Re: discontinuous range query

2006-10-05 Thread Erik Hatcher
On Oct 5, 2006, at 4:59 AM, Tom Hill wrote: It's clear that my problem here comes from a lack of understanding of the semantics of SHOULD, MUST, and MUST_NOT. I haven't found a clear description of this (except for a brief comment here http://mail-archives.apache.org/mod_mbox/lucene-java-

Re: Sudden FileNotFoundException

2006-10-05 Thread Hes Siemelink
Not making much progress, but there is one thing I found curious: very often the file that can not be found is "_8km.fnm". Is it possible to derive any information from this? Cheers, Hes.

discontinuous range query

2006-10-05 Thread Tom Hill
Hi - Thanks, Yonik, Chris and Doron for the quick responses. Doron's comment about combining the queries was the key to what was causing me problems. I had indeed been combining with other queries, which results in 'extra' results being returned. I've attached a sample program below that ill

Re: Advantage of putting lucene index in RDBMS

2006-10-05 Thread Aleksei Valikov
Hi. I have been reading the lists for couple of week now, and I noticed people asking about placing their indexes into a RDBMS. What is the advantage of that? So far lucene was able to solve all my problems, but I am curious how else people are using it (especially with RDBMS). Having an inde

Different boost values for different terms in a field.

2006-10-05 Thread Frode Bjerkholt
Hi My intention is to give different terms in a field different boost values. The queries from a use perspective, will be one fulltext input field. The following code illustrates this: Field f1 = new Field("name", "John", Field.Store.NO, Field.Index.TOKENIZED); Field f2 = new Field("name", "Doe

[Fwd: Spam filter for lucene project]

2006-10-05 Thread Martin Braun
Hello Rajiv, perhaps captcha's will solve your problem: http://en.wikipedia.org/wiki/CAPTCHA many open-source PHP products are using this like phpmyfaq and phpBB. So you can take a look at this code. hth, martin Original-Nachricht Von: Rajiv Roopan <[EMAIL PROTECTED]> Betre

Re: Find if words are in the same phrase?

2006-10-05 Thread Doron Cohen
I am not sure I understand what you are asking. I assume you are aware of Lucene Proximity Search - e.g. "jakarta apache"~4 - see http://lucene.apache.org/java/docs/queryparsersyntax.html Are you asking if it is possible to search for docs in which the gap between the two words is exactly N, e.g.