Hi Graeme,
I saw something like this once.
But don't remember what was the problem...
Which PHP version do you use?
With best regards,
Alexander Veremyev.
Graeme Merrall wrote:
Hi. I'm trying to sort my search results by an alternate field named
'publication_time'.
$results = $index->find($query, 'publication_time', SORT_NUMERIC,
SORT_DESC);
However, I get an error when I do. This error occurs both in 0.8.0
and the latest snapshot (20070310-3855).
Error is:
Notice: Undefined offset: 4 in
/usr/local/php5/lib/ZendFramework-20070310-3855/library/Zend/Search/Lucene.php
on line 585
Warning: array_multisort() [function.array-multisort]: Argument #3 is
expected to be an array or a sort flag in
/usr/local/php5/lib/ZendFramework-20070310-3855/library/Zend/Search/Lucene.php
on line 608
When I poke around in the code, it seems that the $sortArgs array
passed to array_multisort has had SORT_NUMERIC set empty.
Is this a bug or have I missed something?
Cheers,
Graeme