Hi I have the following type of query:
Select a,b from tab1 whre tab1.id in
(Select id from tab2 where x=1 and y=2 and z>getdate())
Now z is a datetime column in tab2 and it is nullable column.So I want the check z > getdate() only if it is not null. Checked Conditional WHERE clause in SQL Server but could not do it accurately.Basically I dont want the 'z' column check in the above query if it is null in tab2.
Thanks in advance.