[Xapian-discuss] combining databases for omega

Chris Purves chris at northfolk.ca
Mon Dec 31 13:04:08 GMT 2012


On 30/12/2012 2:12 PM, Jim Lynch wrote:
> On 12/30/2012 12:39 PM, Chris Purves wrote:
>> From the documentation I've read, omega can read from multiple
>> databases, but I'm not sure how to go about this.
>>
>> I have three databases created using omindex, currently located at
>> /var/lib/xapian-omega/data/share, /var/lib/xapian-omega/data/users,
>> and /var/lib/xapiax-omega/data/management
>>
>> The quickstart guide says that in omega.conf database_dir should point
>> to the directory containing my database(s), but if I set it to
>> /var/lib/xapian-omega/data it only looks for the default directory.
>>
>> Can I configure omega to search multiple databases or should I use
>> something like xapian-compact to merge the three into one?
>>
>>
> One way to do this is with a stub database.  This example is stolen from
> an email asking for help.
>
> Databases:
> /var/lib/xapian-omega/data/db1
> /var/lib/xapian-omega/data/db2
> /var/lib/xapian-omega/data/db3
>
> Stub:
> /var/lib/xapian-omega/data/default
>
> The stub file "default" is a text file that contains the following:
> auto /var/lib/xapian-omega/data/db1
> auto /var/lib/xapian-omega/data/db2
> auto /var/lib/xapian-omega/data/db3
>
>
> /usr/lib/cgi-bin/omega/omega 'DB=default' 'P=searchphrase' 'FMT=xml'
>
> The file doesn't have to be named default.
>


I was able to get it working.  I only included the three 'auto' lines 
and it worked fine.  Thanks!


-- 
Chris Purves
Visit my blog: http://chris.northfolk.ca

"Whence come I and whither go I? That is the great unfathomable 
question, the same for every one of us. Science has no answer to it." - 
Max Planck



More information about the Xapian-discuss mailing list