devxlogo

IIF Function Under SQL Server 7.0

IIF Function Under SQL Server 7.0

Question:
Is the IIF function valid under SQL server 7.0? It’s in the SQL Books Online as valid, but none of my stored procedures accept it.

Answer:
The IIF function you refer to in Books Online isn’t part of the T-SQL syntax that your stored procedures expect. Instead it is used when writing code for Microsoft’s OLAP services. In T-SQL you will have to expand the statement to if.. then.. else..

devxblackblue

About Our Editorial Process

At DevX, we’re dedicated to tech entrepreneurship. Our team closely follows industry shifts, new products, AI breakthroughs, technology trends, and funding announcements. Articles undergo thorough editing to ensure accuracy and clarity, reflecting DevX’s style and supporting entrepreneurs in the tech sphere.

See our full editorial policy.

About Our Journalist