In Sql Server when i run query :
Select Case when 5>2 then 1
else 2 end
its working perfectly, But when i run the below query its showing error ?
Query : Select 5 > 2
Output:
Msg 102, Level 15, State 1, Line 17
Incorrect syntax near '>'.
Why error ? instead of displaying True or false or 1 or 2? on comparison .

Nilesh ShahPosted May 19, 2017, 10:41 AM
Gagan SharmaPosted May 19, 2017, 12:14 AM
Nilesh ShahPosted May 18, 2017, 11:45 AM
Guest UserPosted May 16, 2017, 5:39 AM