Results 1 to 2 of 2

Thread: IIF in SQL

  1. #1
    Join Date
    Oct 2003
    Location
    Manila, Philippines
    Posts
    20

    Unanswered: IIF in SQL

    hello!

    In MS ACCESS 2000, I can use the IIF function like (
    SELECT IIF(x>0, "True","False") from x_table.
    I tried the ISNULL but got a wrong ouput.

    How can I do this also in MS SQL?

    Please help...

    Any effort is higly appreciated.


    Thanks

  2. #2
    Join Date
    Apr 2002
    Location
    Toronto, Canada
    Posts
    20,002
    select case when x>0 then 'True' else 'False' end
    from x_table


    rudy

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •