Posted on 2009-02-11
I need to modify a sql query and I need some help. Here is the original case statement that works.
when (biddate > saledate) or saledate is null then biddate
when biddate <= saledate then saledate
end as anchordt,
However, I need to add this if/then clause or something. When bidstatus='Y' then I the anchotdt to be getdate(). I cannot get it working. I always get null values. Biddate should be null when Bidstatus is "y" and I don't know if that is messing it up or not.