Boston Linux & Unix (BLU) Home | Calendar | Mail Lists | List Archives | Desktop SIG | Hardware Hacking SIG
Wiki | Flickr | PicasaWeb | Video | Maps & Directions | Installfests | Keysignings
Linux Cafe | Meeting Notes | Linux Links | Bling | About BLU

BLU Discuss list archive


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

PHP/MySQL Query Database with Variable number of fields



I waant to be able to query on any of thes fields or any combination of
these fields

I Know how to query any one field or multiple fields but want I want to do
is have field1, Field2 and Field3 populated in a drop-down list and query my
database given the number of fields that are selected.. (maybe just query
Field1 or query field1 and Field3)


I really hope that makes sense... (i'm a little flustered :) )


ie

where field1 = 1
or Where Field1=1 and Field3=no

or any combination....

Database
Field1, Field2, Field3
a      1        yes
b          2        no
c          3        maybe
d        (blank)  yes


Thanks in advance



-- 
-- 
Myrle A. Francis 2nd

PgpServer(s): pgp.mit.edu

Type bits /keyID    Date       User ID
pub  1024D/30BDB814 2006/07/27 Myrle A. Francis 2nd <mafmanet-Re5JQEeQqe8AvxtiuMwx3w at public.gmane.org>
     Key fingerprint = 73E3 6EAF EC29 29A3 94F9  6C78 F427 0FE8 30BD B814






BLU is a member of BostonUserGroups
BLU is a member of BostonUserGroups
We also thank MIT for the use of their facilities.

Valid HTML 4.01! Valid CSS!



Boston Linux & Unix / webmaster@blu.org