I am trying to query data simply like,
select * from product where (color='blue' or type='suv')
I want any particular data having "color" and "type" as mentioned in query but if i do not mention him "type" then it will get data from only "color".
For example:
product color type
toyota red suv
honda black
select * from product where (color='blue' or type Is null)
In second query it return me both "toyota" and "honda".
What I need is to get product if I give its "color" value then it return data by its color only and if I give its "color" and "type" value then return data according to both values?