[Date Prev][Date Next][Thread Prev][Thread Next][Minivend by date
][Minivend by thread
]
[mv] Sql search with multiple mv_search_field
****** message to minivend-users from Ken Berland <ken@hero.com> ******
With MiniVend V3.14-3, I'm using the following form to to a three
mv_search_field search with sql. Is anyone doing this successfully? I'm
getting some weird behaviour. I did the same thing in a "one click search"
and it works fine.
I'd like them all to "AND" together. When all
are blank the sql is query is correct, 1=1. When all are filled the
query is also correct, select code from products where code like '%1%' AND
fixture_type like '%2%' AND manufacturer like '%3%'. But when only two is
filled in I get, select code from products where code like '%%' OR
fixture_type like '%%' OR manufacturer like '%%'.
<FORM ACTION="[process-search]" METHOD=POST>
<INPUT TYPE="hidden" NAME="mv_searchtype" VALUE="sql">
<INPUT TYPE="hidden" NAME="mv_orsearch" VALUE="no">
<INPUT TYPE="hidden" NAME="mv_matchlimit" VALUE="15">
<INPUT TYPE="hidden" NAME="mv_return_all" VALUE="yes">
<INPUT TYPE="hidden" NAME="mv_search_field" VALUE="code">
<INPUT TYPE="hidden" NAME="mv_search_field" VALUE="fixture_type">
<INPUT TYPE="hidden" NAME="mv_search_field" VALUE="manufacturer">
<INPUT TYPE="hidden" NAME="mv_case" VALUE="no">
<INPUT TYPE="hidden" NAME="mv_substring_match" VALUE="yes">
<INPUT TYPE="hidden" NAME="mv_coordinate" VALUE="yes">
Item Number:
<INPUT TYPE="TEXT" NAME="mv_searchspec" SIZE="20" MAXLENGTH="30"><BR>
Fixture Type:
<INPUT TYPE="TEXT" NAME="mv_searchspec" SIZE="20" MAXLENGTH="30"><BR>
Manufacturer:
<INPUT TYPE="TEXT" NAME="mv_searchspec" SIZE="20" MAXLENGTH="30"><BR>
<INPUT TYPE="submit" VALUE="Go">
</FORM>
<!--one click search that works-->
Buffers Files Tools Edit Search Mule Tcl-Mode Help
[page scan st=sql
ra=yes
os=no
ml=15
cs=no
su=yes
sf=code
sf=fixture_type
sf=manufacturer
se=
se=wall
se=resolut]
DOIT[/page]
-
To unsubscribe from the list, DO NOT REPLY to this message. Instead, send
email with 'UNSUBSCRIBE minivend-users' in the body to Majordomo@minivend.com.
Archive of past messages: http://www.minivend.com/minivend/minivend-list