[ic] Search problem when mixing words around.
Rick Bragg
lists at gmnet.net
Mon Aug 31 10:09:10 UTC 2009
On Fri, 2009-08-28 at 19:20 +0300, Gert van der Spoel wrote:
> > -----Original Message-----
> > From: interchange-users-bounces at icdevgroup.org [mailto:interchange-
> > users-bounces at icdevgroup.org] On Behalf Of Rick Bragg
> > Sent: Friday, August 28, 2009 1:26 AM
> > To: interchange-users at icdevgroup.org
> > Subject: [ic] Search problem when mixing words around.
> >
> > Hi,
> >
> > I have a simple search form that I can't seem to get to work properly.
> >
> > following is a sample of my simple form:
> >
> > <form action="[area search]" method=post>
> > [form-session-id]
> > <INPUT TYPE=hidden NAME=mv_coordinate VALUE="1">
> > <INPUT TYPE=hidden NAME=mv_searchtype VALUE="db">
> >
> > <INPUT MAXLENGTH=30 NAME=mv_searchspec type=text size=15>
> > <INPUT TYPE=hidden NAME=mv_search_field VALUE=":description:comment">
> > <INPUT TYPE=hidden
> > NAME=mv_column_op
> > VALUE="rm">
> > <INPUT TYPE=hidden NAME=mv_substring_match VALUE="1">
> > <INPUT TYPE=hidden NAME=mv_all_chars VALUE="1">
> > <INPUT TYPE=hidden NAME=mv_exact_match VALUE="0">
> >
> > <INPUT TYPE=hidden NAME=mv_matchlimit VALUE="[control matches 25]">
> > <INPUT TYPE=hidden NAME=mv_sort_field VALUE="description">
> >
> > <input type=submit value="[L]SEARCH[/L]" class="search_button">
> > </form>
> >
> > It seems that it is doing substring matches fine. For example, I search
> > for "icycl" and it finds everything with "bicycle" perfectly. I can
> > also search for "fixed gear" or "ixed gea" and it finds everything with
> > "fixed gear" perfectly.
> >
> > However, if I search for "gear fixed" it finds nothing and I get an
> > error...
> > Errors:
> > Unknown mv_column_op (ARRAY(0x533a890))
> >
> > So it seems that it can find substring fine, but for some reason it
> > can't find things where words are rearranged.
> >
> > Am I doing something wrong, or is this the right behavior? Is there a
> > simple way to fix this so that searches for things like "gear fixed"
> > return rows with "fixed gear" in them?
> >
> > Thanks!
> > Rick
> >
>
> I copied the above and tested in on my local version and I have not been
> able to reproduce.
> http://ic.3edge.com/ic/test2.html
>
> Search for 'rgo rol' and it will give you 'ergo roller'
> Search for 'roller ergo' and it will give you 'no matches found' ....
>
> The reason that it returns (ARRAY(0x533a890)) is because in
> lib/Vend/Search.pm at some point you will find:
> $s->search_error("Unknown mv_column_op (%s)",$o); (search for
> 'Unknown' will give you one location).
>
> $o is a scalar containing the op ...
>
> However sub search_error has:
> my ($s, $msg, @args) = @_;
>
> $o ends up in @args ...
>
> That does not seem right to me ...
>
> CU,
>
> Gert
>
It is expected that a search for "Roller Ergo" will return nothing?
Actually, I do want to find "Ergo Roller" when I search for "Roller
Ergo" Also a search for "Roller-Ergo" should produce the same results.
Is there a way to "tokenize" the search spec at all? The Array error
issue may be un-related...
Thanks!
rick
--
This message has been scanned for viruses and
dangerous content by Green Mountain Network, and is
believed to be clean.
More information about the interchange-users
mailing list