I am trying to set a condition to a field in sp
If SI0_ADDR.ADDR_EXPR_DATE = '1001-01-01' or > currentDate(), display address active flag = 'Y', else display 'N'.
I am trying this
case [ADDR_EXPR_DATE]
when '1001-01-01'||[ADDR_EXPR_DATE] > getdate() then 'Y'
when > (getdate()) then 'N'
else 'N'
end as active_flag