In a SFgate form
there are generally different Input boxes and they can be linked
with boolean operators AND or OR.
The choice of the boolean operator to use could be made using a
drop-down list exactly as for field description selection.
See the document How to perform a simple query?.
Forms created in
languages different from English allow to use localized
(national) Boolean operators.
At the moment the German, Franch, Italian, Dutch, Swedish,
Spanish and Portoguese boolean operators are supported.
For example, Boolean operators of the Italian language are E
and O.
Please note that sometimes boolean
operators are not declared (they are hidden). There is a unique
Boolean Operator that joins all the Input Boxes of the form.
If you want to see what is the boolean operator in this case, you
should inspect the form source code and search for a tag
like the one reported below:
<INPUT TYPE="hidden" NAME="tie" VALUE="and">
Example #1
This LIVE example allows only to select the boolean operator to connect fields.
Here you can inspect the .fmt file, while the relevant part of this form source code is here:
<FORM METHOD=POST ACTION="/htbin/SFgate"> <INPUT NAME="database" TYPE="hidden" VALUE="local//usr/local/wais-sources/phonebook/phone"> <CENTER> <TABLE BORDER WIDTH=70%> <TR><TH align=left>Surname</TH><TD><INPUT TYPE="text" NAME="surname" VALUE="salviati" SIZE=40></TD> <TD><SELECT NAME="name_tie"> <OPTION>and <OPTION>or </SELECT></TD></TR> <TR><TH align=left>Name</TH><TD><INPUT TYPE="text" NAME="name" VALUE="giovanni" SIZE=40></TD></TR> </TABLE> </CENTER> <P> <CENTER> <TABLE> <TR><TH><INPUT TYPE="submit" VALUE="Start Search"> </TH><TH> </TH><TH> <INPUT TYPE="reset" VALUE="Reset Query"> </TR></TABLE> </CENTER> <INPUT TYPE="hidden" NAME="tieinternal" VALUE="and"> <INPUT TYPE="hidden" NAME="application" VALUE="phone"> <INPUT TYPE="hidden" NAME="directget" VALUE="1"> <INPUT TYPE="hidden" NAME="convert" VALUE="Table"> </FORM>
Example #2
This LIVE example allows to select both the fields and the boolean operators. Try to use this form modifying only the boolean operator at the beginning. Then, on the basis of what you have back, try also to modify default terms of the Input Boxes.
Here you can inspect the .fmt file, while the relevant part of this form source code is here:
<FORM METHOD=POST ACTION="/htbin/SFgate"> <INPUT NAME="database" TYPE="hidden" VALUE="phone_attribute"> <CENTER> <TABLE BORDER WIDTH=70%> <TR><TD><SELECT NAME="fieldsel_1_description"> <OPTION SELECTED>Surname <OPTION>Name <OPTION>Department </SELECT></TD> <TD><INPUT TYPE="text" NAME="fieldsel_1_content" VALUE="salviati" SIZE=40></TD> <TD><SELECT NAME="fieldsel_1_tie"> <OPTION>and <OPTION>or </SELECT></TD></TR> <TR><TD><SELECT NAME="fieldsel_2_description"> <OPTION>Surname <OPTION SELECTED>Name <OPTION>Department </SELECT></TD> <TD><INPUT TYPE="text" NAME="fieldsel_2_content" VALUE="giovanni" SIZE=40></TD></TR> </TABLE> </CENTER> <INPUT TYPE="hidden" NAME="fieldsel_name_surname" VALUE="Surname"> <INPUT TYPE="hidden" NAME="fieldsel_name_name" VALUE="Name"> <INPUT TYPE="hidden" NAME="fieldsel_name_department" VALUE="Department"> <P> <CENTER> <TABLE> <TR><TH><INPUT TYPE="submit" VALUE="Start Search"> </TH><TH> </TH><TH> <INPUT TYPE="reset" VALUE="Reset Query"></TR> </TABLE> </CENTER> <INPUT TYPE="hidden" NAME="tieinternal" VALUE="and"> <INPUT TYPE="hidden" NAME="application" VALUE="phone"> <INPUT TYPE="hidden" NAME="directget" VALUE="1"> <INPUT TYPE="hidden" NAME="convert" VALUE="Table"> <INPUT TYPE="hidden" NAME="attributes" VALUE="1"> <INPUT TYPE="hidden" NAME="lattice" VALUE="phone_lattice"> </FORM>
Example #3
In this form you can choose the boolean operator connecting fields, while inside each field an OR connects the terms.
Here you can inspect the .fmt file, while the relevant part of this form source code is here:
<FORM METHOD=POST ACTION="/htbin/SFgate"> <INPUT NAME="database" TYPE="hidden" VALUE="local//usr/local/wais-sources/tutorial/audio"> <CENTER> <TABLE BORDER> <TR><TH> </TH><TH> <TABLE BORDER WIDTH="100%"> <TR><TH ALIGN=center COLSPAN=3>MODE OF INHERITANCE</TH></TR> <TR><TD><INPUT TYPE="checkbox" NAME="inheritance_content" VALUE="dominant" CHECKED> Autosomal Dominant</TD> <TD><INPUT TYPE="checkbox" NAME="inheritance_content" VALUE="x-linked_dominant" CHECKED> X-linked Dominant</TD> <TD><INPUT TYPE="checkbox" NAME="inheritance_content" VALUE="polygenic"> Polygenic</TD></TR> <TR><TD><INPUT TYPE="checkbox" NAME="inheritance_content" VALUE="recessive"> Autosomal Recessive</TD> <TD><INPUT TYPE="checkbox" NAME="inheritance_content" VALUE="x-linked_recessive"> X-linked Recessive</TD> <TD><INPUT TYPE="checkbox" NAME="inheritance_content" VALUE="unknown"> Unknown</TD></TR> <TR><TD><INPUT TYPE="checkbox" NAME="inheritance_content" VALUE="mitochondrial"> Mitochondrial</TD></TR> </TABLE> </TH></TR> <TR><TD> <SELECT NAME="freqimpair_tie"> <OPTION>and <OPTION>or </SELECT> </TD></TR> <TR><TH> </TH><TH> <TABLE BORDER WIDTH=100%> <TR><TH ALIGN=center COLSPAN=4>RANGE OF FREQUENCY IMPAIRMENT</TH></TR> <TR><TD><INPUT TYPE="checkbox" NAME="freqimpair_content" VALUE="low" CHECKED> Low</TD> <TD><INPUT TYPE="checkbox" NAME="freqimpair_content" VALUE="high"> High</TD> <TD><INPUT TYPE="checkbox" NAME="freqimpair_content" VALUE="mid+high"> Mid+High</TD> <TD><INPUT TYPE="checkbox" NAME="freqimpair_content" VALUE="extended_high"> Extended High</TD></TR> <TR><TD><INPUT TYPE="checkbox" NAME="freqimpair_content" VALUE="mid"> Mid</TD> <TD><INPUT TYPE="checkbox" NAME="freqimpair_content" VALUE="low+mid"> Low+Mid</TD> <TD><INPUT TYPE="checkbox" NAME="freqimpair_content" VALUE="low+high"> Low+High</TD> <TD><INPUT TYPE="checkbox" NAME="freqimpair_content" VALUE="frequencies"> All Frequencies</TD></TR> </TABLE> </TH></TR> <TR><TH> </TH><TH> <TABLE WIDTH=100%> <TR><TD WIDTH=50%><B>Low:</B> < 500Hz</TD><TD><B>High:</B> > 2000Hz and =< 8000Hz</TD></TR> <TR><TD WIDTH=50%><B>Mid:</B> 500 - 2000Hz</TD><TD><B>Extended High:</B> > 8000Hz </TD></TR> </TABLE> </TH></TR> </TABLE> </CENTER> <P> <CENTER> <TABLE> <TR><TH><INPUT TYPE="submit" VALUE="Start Search"> </TH><TH> </TH><TH> <INPUT TYPE="reset" VALUE="Reset Query"></TR> </TABLE> </CENTER> <INPUT TYPE="hidden" NAME="tieinternal" VALUE="or"> <INPUT TYPE="hidden" NAME="listenv" VALUE="table"> <INPUT TYPE="hidden" NAME="range" VALUE="1"> <INPUT TYPE="hidden" NAME="convert" VALUE="Table"> <INPUT TYPE="hidden" NAME="maxhits" VALUE="30"> <INPUT TYPE="hidden" NAME="directget" VALUE="1"> <input type="hidden" name="application" value="audio"> </FORM>
© 1996-2003 BioPD -
University of Padova (Italy) - Author: Leopoldo
Saggin - Last version: January
28, 2003
Best efforts were made to provide correct information, however
this document may contain technical inaccuracies and/or
typographical errors.
The author declares that this material is provided "as
is" without any warranty even in the implied warranty of
merchantability or fitness for a particular purpose.
All trademarks cited inside this document are property of their
respective owners