search multiple fields
Posted 09 February 2004 - 07:51 PM
I guess my real question is how to setup a single entry that will span across multiple fields when it does it's search.
Posted 09 February 2004 - 07:58 PM
$result = mysql_query ("select * from TABLE where FIELDNAME like '%$txtsearch%' order by FIELDNAME"); ($row = mysql_fetch_array($result))
The [*] pulls all fields from that table.
If you wished to see only one field replace then [*] with [FIELDNAME]
Multi fields [FIELDNAME1, FIELDNAME2]
then to pull the field data
print ("<TD>"); print $row["FIELDNAME"]; print ("</TD>");
Posted 11 February 2004 - 09:59 PM
What I meant was...I want to have a single text search box. In this box users will be able to type in any client contact info they want(it will be based on a client contact table). They could type in "3333333333" for a phone number or type in "Billy Bob" or type in "33 Test Rd". From their input the search would look at all fields in the table and return anything that matched. It wouldn't search for a match only on one field. Is this possible? Would it bog down the server on 10 thousand records, 250,000 records?
Posted 12 February 2004 - 03:59 PM
0 user(s) are reading this topic
0 members, 0 guests, 0 anonymous users