Please start any new threads on our new
site at https://forums.sqlteam.com. We've got lots of great SQL Server
experts to answer whatever question you can come up with.
| Author |
Topic |
|
AskSQLTeam
Ask SQLTeam Question
0 Posts |
Posted - 2005-01-07 : 08:59:21
|
| tal writes "I saw in SqlServer Help the iif() function.When i try to use this sql :select iif(dateCol=getdate(),1,0) from DatesTbli get an error :incorrect syntax near '='.why ?where is my sin ?thank you,tal" |
|
|
spirit1
Cybernetic Yak Master
11752 Posts |
Posted - 2005-01-07 : 09:08:38
|
there is no iif in sql server. there's case:select case when dateCol=getdate() then 1 else 0 endfrom DatesTblGo with the flow & have fun! Else fight the flow |
 |
|
|
|
|
|