[Xapian-discuss] Just starting to experiment with php
Jim Lynch
jim at fayettedigital.com
Fri Jun 10 15:04:19 BST 2011
I took one of the examples and tried to run against my database
ls -l /data1/mail/db/cur.1
total 1129624
-rw-r--r-- 1 jwl jwl 0 2011-06-09 02:27 flintlock
-rw-r--r-- 1 jwl jwl 28 2011-06-09 02:27 iamchert
-rwxrwxrwx 1 jwl jwl 7258 2011-06-09 02:27 position.baseA
-rwxrwxrwx 1 jwl jwl 7046 2011-06-09 02:27 position.baseB
-rwxrwxrwx 1 jwl jwl 474226688 2011-06-09 02:28 position.DB
-rwxrwxrwx 1 jwl jwl 5626 2011-06-09 02:28 postlist.baseA
-rwxrwxrwx 1 jwl jwl 5331 2011-06-09 02:28 postlist.baseB
-rwxrwxrwx 1 jwl jwl 367476736 2011-06-09 02:28 postlist.DB
-rwxrwxrwx 1 jwl jwl 734 2011-06-09 02:28 record.baseA
-rwxrwxrwx 1 jwl jwl 725 2011-06-09 02:28 record.baseB
-rwxrwxrwx 1 jwl jwl 46923776 2011-06-09 02:28 record.DB
-rwxrwxrwx 1 jwl jwl 3530 2011-06-09 02:28 termlist.baseA
-rwxrwxrwx 1 jwl jwl 3439 2011-06-09 02:28 termlist.baseB
-rwxrwxrwx 1 jwl jwl 230023168 2011-06-09 02:28 termlist.DB
-rwxrwxrwx 1 jwl jwl 581 2010-07-18 00:36 value.baseA
-rwxrwxrwx 1 jwl jwl 576 2010-07-18 00:36 value.baseB
-rwxrwxrwx 1 jwl jwl 36864000 2010-07-18 00:36 value.DB
php ex.php /data1/mail/db/cur.1 henry
DatabaseOpeningError: Couldn't detect type of database
From the ex.php file:
include "/usr/share/php/xapian.php";
if ($argc < 3) {
print "Usage: {$argv[0]} PATH_TO_DATABASE QUERY\n";
exit(1);
}
// Open the database for searching.
try {
$database = new XapianDatabase($argv[1]);
// Start an enquire session.
$enquire = new XapianEnquire($database);
...
What did I miss?
More information about the Xapian-discuss
mailing list