Re: command line syntax when searching for multiple fields
Brad Miele <[email protected]> Wed, 1 Nov 2006 04:59:34 -0800 (PST)
| Newsgroups | gmane.comp.web.swish-e |
|---|---|
| Message-ID | <[email protected]> |
just wondering, why aren't you using the Swish::API perl module for this? It would make the issue much easier to debug IMHO. at any rate, if you can create a command line like this: swish-e -w author=$author costcenter=$costcenter -f blah.index it really should work, our index has about 30 custom metanames and we have no issue with searching them. have you also done swish-e -T INDEX_METANAMES to confirm that both are available? regards, Brad --------------------- Brad Miele VP Technology IPNStock.com 866 476 7862 x902 [email protected] On Wed, 1 Nov 2006, Cas Tuyn wrote: > Hi, > > To create advanced search I added two extra search boxes, author and > costcenter. > Field names are: QUERY, au and cc > > Inside my Perl script I have: > > foreach $option(@options) { > ($name, $value)=split('=', $option); > if ($name eq "QUERY") { > $query=$value; > } > if ($name eq "P") { > $position = $value; > } > if ($name eq "au") { > $qauthor = $value; > } > if ($name eq "cc") { > $qcc = $value; > } > } > open (SWISH, "/web/bin/swish-e-2.4.3/bin/swish-e -f $index -H 9 -d :: > -b $position -m 10 -p description author -w $query \"author=$qauthor\" > \"costc=$qcc\" |"); > > so the URL contains: search.pl?QUERY=&au=cas&cc=nl017016 > when I only search for author and costcenter > > My problem is that only the regular query and author fields seem to > work. When I search exclusively for a costcenter: > search.pl?QUERY=&au=&cc=nl017016 > I find nothing, and in combination with author it does not make a > difference with or without costcenter. > > Does anybody have tips to search for self-generated Metanames? > > I already verified that Swish-e knows the 'costc' metaname, I can even > show it in the search output if I place "costc" between the "-p > description" and "author" in the command, then I see the costcenter > instead of the authorname in the search output. > > My config = Swish-e 2.4.3 on Solaris 2.8 > > Regards, > > Cas > >