I want know how to add an input(field) on sql query.
IF THIS input IS NULL THEN
You'd want to use a UNION statement.
select '', '-- select one --'
select [ValueColumn], [NameColumn]
where [enabled] = 1
order by 2
Thank you Brenden Kehren for your Answer.
But I want to check,
If this input(field of a form) is null then execute the select.
Please, sign in to be able to submit a new answer.