In TSQL WHERE clause, does the Truth Table logic apply?
For instance I have the following code:
WHERE (@Flag = 0 AND Title LIKE '%...%') OR (@Flag = 1 AND Title = '...')
In case @Flag = 0, First () will be True and second () will be False. So True OR False would result in True, hence, the second () won't have an effect on the query result. Is that true?
Thanks