[ic] Trouble with coordinated search to test for inactive
Ron Phipps
rphipps at reliant-solutions.com
Thu Apr 8 02:16:56 EDT 2004
> From: Ron Phipps
>
> > From: Mike Heins
> > Sent: Wednesday, April 07, 2004 12:20 PM
> > To: interchange-users at icdevgroup.org
> > Subject: Re: [ic] Trouble with coordinated search to test for
inactive
> >
> > Quoting Ron Phipps (rphipps at reliant-solutions.com):
> > > I read your thread and many others last night and was just being
> > > stubborn figuring there has to be a way :) I just wrote a query
> page in
> > > 10x less the time I experimented with the built in search. Take
it
> > > easy!
> > >
> >
> > You didn't mention if you tried my:
> >
> > co=1
> > sf=import_inactive
> > se=0
> > op=eq
> > sf=user_inactive
> > se=0
> > op=eq
> > sf=:long_description,short_description,title
> > se=test
> >
>
> Hi Mike,
>
> I tried your example and it looks like the search only pays attention
to
> the check for test in long_description or short_description or title.
> It is returning records that have user_inactive or import_inactive set
> to 1 which it should not be doing. Any ideas?
>
> > It is easy to write a custom search that works in one instance,
> > but you will rewrite it every time in the future unless you
> > standardize somewhere.
> >
> > Also, since IC now supports the Text::Query module, if that is
> > installed you get the standard search mechanisms:
> >
> > test NEAR foo
> > test NOT foo
> > "exact phrase" AND qualifier
> >
> > In addition, when you write custom stuff based on SQL it may operate
> > differently on different databases -- Postgres is case-sensitive,
> MySQL
> > is not, for example. Also you likely you have done very little
> checking
> > on boundary conditions.
> >
> > There is nothing wrong with custom searches. It is just important
> > to know the downsides and counterpoints.
>
> I'm seeing this more and more as I work with my custom query page.
I'd
> really like to use the built in search, but there is no reason
apparent
> to me why these searches are not working.
>
> -Ron
>
Mike wrote me back with another example to try, this time using ":" as
the column separator. The following ended up solving my problem:
sp=search_results2
st=db
co=yes
fi=products
sf=user_inactive
se=0
op===
sf=import_inactive
se=0
op===
sf=:long_description:short_description:title:sku
se=test
op=aq
Mike explained the following:
"The "aq" type brings in the typical search-engine search language (OR
NOT AND NEAR) if you have Text::Query, but falls back to regex"
Thanks Paul, Racke and Mike for their help in resolving this issue!
-Ron
More information about the interchange-users
mailing list