Login | Register For Free | Help
Search for: (Advanced)

Mailing List Archive: Lucene: Java-Dev

[jira] Updated: (LUCENE-372) Unmatched right parentheses truncates query

 

 

Lucene java-dev RSS feed   Index | Next | Previous | View Threaded


jira at apache

Oct 28, 2006, 12:18 AM

Post #1 of 5 (1243 views)
Permalink
[jira] Updated: (LUCENE-372) Unmatched right parentheses truncates query

[ http://issues.apache.org/jira/browse/LUCENE-372?page=all ]

Andreas Neumann updated LUCENE-372:
-----------------------------------

Attachment: Lucene-372.patch

This patch contains 5 files (I was not sure whether to include the JavaCC-generated files, ended up including them):
- QueryParser.jJ: introduced a new nonterminal TopLevelQuery
- QueryParser.java: generated from QueryParser.jj by javaCC
- QueryParserTokenManager.java: generated from QueryParser.jj by javaCC
- TestQueryParser.java: rewrote testException and added a few more tests.
- TestMultiFieldQueryParser.java: fixed testSimple() because it was passing in unbalanced quotation marks. That caused a failure with the new QueryParser.

- Andreas.


> Unmatched right parentheses truncates query
> -------------------------------------------
>
> Key: LUCENE-372
> URL: http://issues.apache.org/jira/browse/LUCENE-372
> Project: Lucene - Java
> Issue Type: Bug
> Components: QueryParser
> Affects Versions: 1.4
> Environment: Operating System: Linux
> Platform: PC
> Reporter: Patrick Hochstenbach
> Assigned To: Lucene Developers
> Attachments: Lucene-372.patch
>
>
> The query processor truncates a query when right parentheses are unmatched.
> E.g.:
> secret AND illegal) AND access:confidential
> will not result in a ParseException instead will run as:
> secret AND illegal

--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira



---------------------------------------------------------------------
To unsubscribe, e-mail: java-dev-unsubscribe [at] lucene
For additional commands, e-mail: java-dev-help [at] lucene


jira at apache

Oct 28, 2006, 12:18 AM

Post #2 of 5 (1172 views)
Permalink
[jira] Updated: (LUCENE-372) Unmatched right parentheses truncates query [In reply to]

[ http://issues.apache.org/jira/browse/LUCENE-372?page=all ]

Andreas Neumann updated LUCENE-372:
-----------------------------------

Attachment: Lucene-372.patch

This patch contains 5 files (I was not sure whether to include the JavaCC-generated files, ended up including them):
- QueryParser.jJ: introduced a new nonterminal TopLevelQuery
- QueryParser.java: generated from QueryParser.jj by javaCC
- QueryParserTokenManager.java: generated from QueryParser.jj by javaCC
- TestQueryParser.java: rewrote testException and added a few more tests.
- TestMultiFieldQueryParser.java: fixed testSimple() because it was passing in unbalanced quotation marks. That caused a failure with the new QueryParser.

- Andreas.


> Unmatched right parentheses truncates query
> -------------------------------------------
>
> Key: LUCENE-372
> URL: http://issues.apache.org/jira/browse/LUCENE-372
> Project: Lucene - Java
> Issue Type: Bug
> Components: QueryParser
> Affects Versions: 1.4
> Environment: Operating System: Linux
> Platform: PC
> Reporter: Patrick Hochstenbach
> Assigned To: Lucene Developers
> Attachments: Lucene-372.patch
>
>
> The query processor truncates a query when right parentheses are unmatched.
> E.g.:
> secret AND illegal) AND access:confidential
> will not result in a ParseException instead will run as:
> secret AND illegal

--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira



---------------------------------------------------------------------
To unsubscribe, e-mail: java-dev-unsubscribe [at] lucene
For additional commands, e-mail: java-dev-help [at] lucene


jira at apache

Nov 1, 2006, 9:40 AM

Post #3 of 5 (1127 views)
Permalink
[jira] Updated: (LUCENE-372) Unmatched right parentheses truncates query [In reply to]

[ http://issues.apache.org/jira/browse/LUCENE-372?page=all ]

Steven Parkes updated LUCENE-372:
---------------------------------

Attachment: LUCENE-372.patch.txt

Somehow the patch got some extra line feeds in some of the javacc created files. This version takes those out.

> Unmatched right parentheses truncates query
> -------------------------------------------
>
> Key: LUCENE-372
> URL: http://issues.apache.org/jira/browse/LUCENE-372
> Project: Lucene - Java
> Issue Type: Bug
> Components: QueryParser
> Affects Versions: 1.4, 2.0.0, 1.9, 2.0.1, 2.1
> Environment: Operating System: Linux
> Platform: PC
> Reporter: Patrick Hochstenbach
> Assigned To: Lucene Developers
> Fix For: 2.1
>
> Attachments: Lucene-372.patch, LUCENE-372.patch.txt
>
>
> The query processor truncates a query when right parentheses are unmatched.
> E.g.:
> secret AND illegal) AND access:confidential
> will not result in a ParseException instead will run as:
> secret AND illegal

--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira



---------------------------------------------------------------------
To unsubscribe, e-mail: java-dev-unsubscribe [at] lucene
For additional commands, e-mail: java-dev-help [at] lucene


jira at apache

Nov 1, 2006, 9:40 AM

Post #4 of 5 (1134 views)
Permalink
[jira] Updated: (LUCENE-372) Unmatched right parentheses truncates query [In reply to]

[ http://issues.apache.org/jira/browse/LUCENE-372?page=all ]

Steven Parkes updated LUCENE-372:
---------------------------------

Attachment: LUCENE-372.patch.txt

Somehow the patch got some extra line feeds in some of the javacc created files. This version takes those out.

> Unmatched right parentheses truncates query
> -------------------------------------------
>
> Key: LUCENE-372
> URL: http://issues.apache.org/jira/browse/LUCENE-372
> Project: Lucene - Java
> Issue Type: Bug
> Components: QueryParser
> Affects Versions: 1.4, 2.0.0, 1.9, 2.0.1, 2.1
> Environment: Operating System: Linux
> Platform: PC
> Reporter: Patrick Hochstenbach
> Assigned To: Lucene Developers
> Fix For: 2.1
>
> Attachments: Lucene-372.patch, LUCENE-372.patch.txt
>
>
> The query processor truncates a query when right parentheses are unmatched.
> E.g.:
> secret AND illegal) AND access:confidential
> will not result in a ParseException instead will run as:
> secret AND illegal

--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira



---------------------------------------------------------------------
To unsubscribe, e-mail: java-dev-unsubscribe [at] lucene
For additional commands, e-mail: java-dev-help [at] lucene


jira at apache

Nov 1, 2006, 9:40 AM

Post #5 of 5 (1149 views)
Permalink
[jira] Updated: (LUCENE-372) Unmatched right parentheses truncates query [In reply to]

[ http://issues.apache.org/jira/browse/LUCENE-372?page=all ]

Steven Parkes updated LUCENE-372:
---------------------------------

Lucene Fields: [Patch Available]
Bugzilla Id: (was: 34447)
Fix Version/s: 2.1
Affects Version/s: 2.0.0
1.9
2.0.1
2.1
Assignee: (was: Lucene Developers)
Priority: Minor (was: Major)

I like it. There are some extra tests that demonstrate where parse exceptions are going to be thrown, which is nice.

It would be nice if we could, perhaps, be more liberal in what we accept. For example, I've always thought it would be nice if we could add in missing terminators, e.g., quotes, parentheses., in the spirit of "being liberal in what you accept." But I don't see that being too feasible with an automatically generated parser.

I do think completely ignoring terms, which this patch fixes, is the wrong way to be liberal.

> Unmatched right parentheses truncates query
> -------------------------------------------
>
> Key: LUCENE-372
> URL: http://issues.apache.org/jira/browse/LUCENE-372
> Project: Lucene - Java
> Issue Type: Bug
> Components: QueryParser
> Affects Versions: 1.4, 2.0.0, 1.9, 2.0.1, 2.1
> Environment: Operating System: Linux
> Platform: PC
> Reporter: Patrick Hochstenbach
> Priority: Minor
> Fix For: 2.1
>
> Attachments: Lucene-372.patch, LUCENE-372.patch.txt
>
>
> The query processor truncates a query when right parentheses are unmatched.
> E.g.:
> secret AND illegal) AND access:confidential
> will not result in a ParseException instead will run as:
> secret AND illegal

--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira



---------------------------------------------------------------------
To unsubscribe, e-mail: java-dev-unsubscribe [at] lucene
For additional commands, e-mail: java-dev-help [at] lucene

Lucene java-dev RSS feed   Index | Next | Previous | View Threaded
 
 


Interested in having your list archived? Contact Gossamer Threads
 
  Web Applications & Managed Hosting Powered by Gossamer Threads Inc.