It's sign-style notation. 
'+' means 'required' term
'-' means prohibited
no sign means optional term.
 
So, rewrited query is OK
 
Next step. What is the result of:
-----------------------------
echo Zend_Search_Lucene_Search_QueryParser::parse('published:[1995 TO 
1997]')->rewrite($index)->optimize($index)->__toString() . "\n";
-------------
 
With best regards,
   Alexander Veremyev.



________________________________

        From: Jurriën Stutterheim [mailto:[EMAIL PROTECTED] 
        Sent: Monday, July 30, 2007 11:47 PM
        To: Alexander Veremyev
        Cc: [email protected]
        Subject: Re: [fw-general] Zend_Search_Lucene Ranged Queries
        
        
        Hi Alexander, 
        
        
        The result of the echo is:
        
        
        (published:1995 published:1996 published:1997)
        
        
        Seems like two OR's are missing?
        
        
        As for your second question: yes indeed, I set that analyzer as default 
(for both indexing and searching).
        
        
        On 30 Jul 2007, at 21:35, Alexander Veremyev wrote:


                Hi Jurriën,
                
                
                1. What is the result of:
                -----------------------------
                echo 
Zend_Search_Lucene_Search_QueryParser::parse('published:[1995 TO 
1997]')->rewrite($index)->__toString() . "\n";
                -------------
                
                
                2. It looks like you set TextNum analyzer correctly, but 
nevertheless I should ask. Did you set TextNume analyzer as default while you 
tested range queries?


                With best regards,
                   Alexander Veremyev.


                        -----Original Message-----
                        From: Jurriën Stutterheim [mailto:[EMAIL PROTECTED] 
                        Sent: Monday, July 30, 2007 10:15 PM
                        To: [email protected]
                        Subject: [fw-general] Zend_Search_Lucene Ranged Queries

                        Hi all,

                        I've been trying to get ranged queries to work, but 
                        unfortunatly with little success.
                        When I have the following query:

                        published:1995

                        It successfully lists all books from 1995.
                        But when I have a ranged query it returns 0 hits:

                        published:[1995 TO 1997]

                        What could be the problem?

                        Thanks!



                        Jurriën




Reply via email to