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 Christian Schrader <sc...@evendi.de> on 2001/12/07 12:57:17 UTC

Lexical Error

I just encountered an Error searching for a Term like ${test}.
org.apache.lucene.queryParser.TokenMgrError: Lexical error at line 1, column
1.  Encountered: "$" (36), after : ""

Is this error known?

Chris


--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


*news*

Posted by "Serge A. Redchuk" <bi...@mail.ru>.
Hello, all !

Does anybody know how to perform wildcard search for both: name and
value in field ?
I.e: search for Term( "*news*", "comp*" ); ?

I could not reach it using WildcardQuery or QueryParser :-(


--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


*news* - oops

Posted by "Serge A. Redchuk" <bi...@mail.ru>.
Oops !
I've ment how to search for something like this:
"path:*n* AND rn*" where rn:* is value for some "body"


--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


Re: AW: Lexical Error

Posted by Brian Goetz <br...@quiotix.com>.
> >Is there a good reason, why the QueryParser should throw an Error instead of
> >an Exception?
> >
> Unfortunatly this is the feature of JavaCC and not only of Lucene's 
> QueryParser.

Sort of.  It should be possible to fix this by using a different approach
to token building.

--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


AW: AW: Lexical Error

Posted by Christian Schrader <sc...@evendi.de>.
Couldn't QueryParser catch the Error and throw an Exception?
"Subclasses of Error, unlike subclasses of Exception, should not be caught
and generally cause termination of the program. Subclasses of Error need not
be declared in the throws clause of a method definition."

I am complaining, because my Servlet just crashed, even though it had a
try{}catch(Exception e){}, which should catch everything, unless catching is
worthless anyways (OutOfMemoryError) :-).

> -----Ursprungliche Nachricht-----
> Von: Halacsy Peter [mailto:halacsy.peter@axelero.com]
> Gesendet: December 7, 2001 3:06 PM
> An: Lucene Users List
> Betreff: Re: AW: Lexical Error
>
>
> Christian Schrader wrote:
>
> >Is there a good reason, why the QueryParser should throw an
> Error instead of
> >an Exception?
> >
> Unfortunatly this is the feature of JavaCC and not only of Lucene's
> QueryParser.
>
> peter
>
> >
> >>-----Ursprungliche Nachricht-----
> >>Von: Christian Schrader [mailto:schrader.news@evendi.de]
> >>Gesendet: December 7, 2001 12:57 PM
> >>An: Lucene Users List
> >>Betreff: Lexical Error
> >>
> >>
> >>I just encountered an Error searching for a Term like ${test}.
> >>org.apache.lucene.queryParser.TokenMgrError: Lexical error at
> >>line 1, column
> >>1.  Encountered: "$" (36), after : ""
> >>
> >>Is this error known?
> >>
> >>Chris
> >>
> >>
> >>--
> >>To unsubscribe, e-mail:
> >><ma...@jakarta.apache.org>
> >>For additional commands, e-mail:
> >><ma...@jakarta.apache.org>
> >>
> >>
> >
> >
> >--
> >To unsubscribe, e-mail:
<ma...@jakarta.apache.org>
>For additional commands, e-mail:
<ma...@jakarta.apache.org>
>




--
To unsubscribe, e-mail:
<ma...@jakarta.apache.org>
For additional commands, e-mail:
<ma...@jakarta.apache.org>



--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


Re: AW: Lexical Error

Posted by Halácsy Péter <ha...@axelero.com>.
Christian Schrader wrote:

>Is there a good reason, why the QueryParser should throw an Error instead of
>an Exception?
>
Unfortunatly this is the feature of JavaCC and not only of Lucene's 
QueryParser.

peter

>
>>-----Ursprungliche Nachricht-----
>>Von: Christian Schrader [mailto:schrader.news@evendi.de]
>>Gesendet: December 7, 2001 12:57 PM
>>An: Lucene Users List
>>Betreff: Lexical Error
>>
>>
>>I just encountered an Error searching for a Term like ${test}.
>>org.apache.lucene.queryParser.TokenMgrError: Lexical error at
>>line 1, column
>>1.  Encountered: "$" (36), after : ""
>>
>>Is this error known?
>>
>>Chris
>>
>>
>>--
>>To unsubscribe, e-mail:
>><ma...@jakarta.apache.org>
>>For additional commands, e-mail:
>><ma...@jakarta.apache.org>
>>
>>
>
>
>--
>To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
>For additional commands, e-mail: <ma...@jakarta.apache.org>
>




--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


AW: Lexical Error

Posted by Christian Schrader <sc...@evendi.de>.
Is there a good reason, why the QueryParser should throw an Error instead of
an Exception?

> -----Ursprungliche Nachricht-----
> Von: Christian Schrader [mailto:schrader.news@evendi.de]
> Gesendet: December 7, 2001 12:57 PM
> An: Lucene Users List
> Betreff: Lexical Error
>
>
> I just encountered an Error searching for a Term like ${test}.
> org.apache.lucene.queryParser.TokenMgrError: Lexical error at
> line 1, column
> 1.  Encountered: "$" (36), after : ""
>
> Is this error known?
>
> Chris
>
>
> --
> To unsubscribe, e-mail:
> <ma...@jakarta.apache.org>
> For additional commands, e-mail:
> <ma...@jakarta.apache.org>
>
>


--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>