I have 2 fields I want to send values to within a WHERE
statement.
- If a variable = 0 then set 2 field values to 100.
- If the variable = 1 then set those same 2 field values to 101.
In my imaginary world, somehow this would work:
Where CASE WHEN @ReportType = 0 THEN
od.StatusCd = 100 AND odm.StatusCd = 100
WHEN @ReportType = 1 THEN
od.statusCd = 101 AND odm.StatusCd = 101
End
And od.CompletionDate between ....
And so on....
I know this is wrong. But this is where I am at right now.