passing null to a string parameter
I have recently discovered the ability to pass parameters to a query
using the : notation. My question is: How can I
specify that a string parameter must be assigned to null (if I pass
simply null, it is interpreted as the string 'null' and not the null
value)?
Thanks
Thanks
select *
from t
where
(:fld is null or :fld = t.fld) and <other conditions>
If :fld is null the expression :fld=t.fld is not checked but the other conditions are checked!