views:

84

answers:

0

How can I create a Query to search for a number?

$query->addTerm(new Zend_Search_Lucene_Index_Term('1', 'id'), null);

$query->addTerm(new Zend_Search_Lucene_Index_Term('frank', 'name'), null);

$queryP = Zend_Search_Lucene_Search_QueryParser::parse($query);
$hits = $ix->find($queryP);

echo $queryP;

Returns;

() (name:frank)

To build the index I'm using,

Zend_Search_Lucene_Analysis_Analyzer::setDefault(new Zend_Search_Lucene_Analysis_Analyzer_Common_TextNum_CaseInsensitive());

Thanks, dan Thought Den