2
Is there any material to learn?
For example:
I have a pet shop:
Let’s say in my HTML I have several select boxes (animal, breed, gender, age, etc), in it I can
select the dog or
select dog > breed or
select dog > breed > sex or
select dog > breed > age or
select dog > age > sex or
etc.
and vice versa for multiple options.
How is a query for each of them, and the choices will vary greatly?
select * from nomeTabela WHERE animal='cachorro' AND raca='pintcher'
<- Can you do this dynamic part? Just add the AND
and value dynamically, don’t you? How do I do it? I have to manually produce the whole query for each of the cases? It’s a lot of work, isn’t it?
Try using the WHERE tampo = '' OR field2 = '' OR field3 = ''...
– Sr. André Baill
Maybe that question help
– rray
The answer of this also, can give you an idea of how to elaborate... using if(Empty()): http://answall.com/questions/71394/model-closement-customizar-c%C3%B3digo
– Sr. André Baill