Get Blogged by JoKi

"The only frontiers are in your mind"
22 | 07 | 2017
Navigation
Syndication
Latest Tweets

Most Read Articles
Article Time Line
About me
Family guy, geek, entrepreneur, software craftsman: Visual FoxPro, C#, SQL Server, MySQL, Linux consultant, conference speaker

Certificates & Awards

Microsoft Certified Professional

Microsoft Specialist - Programming in HTML5 with JavaScript and CSS3 Specialist

Get in touch

Sharing is caring

Recent books


Sponsoring
If you like the information on these pages, your support is highly appreciated.
Thank you very much!
Affiliates

 

Spacer for layout formatting

Microsoft and innovation: IIF() method

User Rating:☆☆☆☆☆ / 0
PoorBest 
Development 06 October 2013 - 

This Saturday I was watching a couple of eLearning videos from TrainSignal (thanks to the subscription I have with Pluralsight) on Querying Microsoft SQL Server 2012 (exam 70-461).

'Innovation' by Microsoft

I kept myself busy learning 'new' things about Microsoft SQL Server 2012 and some best practices. It was incredible 'innovative' to see that there is an additional logic function called IIF() available now:

Returns one of two values depending on the value of a logical expression.

IIF(lExpression, eExpression1, eExpression2)

Ups, my bad... That's actually taken from the syntax page of Visual FoxPro 9.0 SP 2. And tada, at least seven (7+) years later, there's the recent IIF() Transact-SQL version of that function:

Returns one of two values, depending on whether the Boolean expression evaluates to true or false in SQL Server 2012.

IIF ( boolean_expression, true_value, false_value )

Now, that's what I call innovation! But we all know what happened to Visual FoxPro... It has been reincarnated in form of Visual Studio LightSwitch (and SQL Server).

Enough ranting... Happy coding!


blog comments powered by Disqus
 
Spacer for layout formatting