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 |
cplusplus
Aged Yak Warrior
567 Posts |
Posted - 2010-07-21 : 11:04:11
|
I am trying to use the following, but getting a message isnull requires 2 arguments:select Case when @ServerSysDate < Acct_Exp_dt or isnull(Acct_Exp_dt) = '' then 'true' Else 'false' End [TF] from tab_users where UserName=@UserNameThank you very much for the helpful info. |
|
cplusplus
Aged Yak Warrior
567 Posts |
Posted - 2010-07-21 : 11:44:27
|
It worked when i used is nullwhen @ServerSysDate < Acct_Exp_dt or Acct_Exp_dt is null then 'true'Thank you.quote: Originally posted by cplusplus I am trying to use the following, but getting a message isnull requires 2 arguments:select Case when @ServerSysDate < Acct_Exp_dt or isnull(Acct_Exp_dt) = '' then 'true' Else 'false' End [TF] from tab_users where UserName=@UserNameThank you very much for the helpful info.
|
 |
|
jimf
Master Smack Fu Yak Hacker
2875 Posts |
Posted - 2010-07-21 : 12:33:09
|
You should ask your company for access to Books On Line. It's free. The isnull function requires 2 argumentsISNULL(Acct_Exp_dt,'') = then 'true' else falseJimEveryday I learn something that somebody else already knew |
 |
|
|
|
|