Just another day, I posted a blog post over here SQL SERVER – NULL Values and CONCAT Function. Lots of people read the blog post and I got quite a few emails on this blog post as well as some interesting conversation on twitter. Based on the suggestions, I have decided to convert the blog into the video of SQL in the Sixty Seconds. Let us learn about CONCAT and NULL – SQL in Sixty Seconds #123.
So here is the question for you – What will be the result of the SELECT CONCAT (NULL, NULL, NULL) statement?
Try to think about the answer before you watch the following video. I think once you watch the video, you will know the answer. One of the primary reasons, I have built this video is to help people who are migrating their SQL Server. I have seen lots of people using the previous method of the plus (+) sign and when they convert it to the newer method of CONCAT, it works just fine till they encounter the NULL value.
I hope this quick video helps anyone who is working with the CONCAT function and NULL value.
Here are a few associated blog posts which you may find interesting.
- Activity Monitor and Running Query – SQL in Sixty Seconds #115
- Email an Execution Plan – SQL in Sixty Seconds #114
- Execution Plan – Estimated vs Actual – SQL in Sixty Seconds #113
- What Happens If the Clustered Index is Disabled? – Interview Question of the Week #291
- Nonclustered Primary Key – SQL in Sixty Seconds #119
- When was Stored Procedure Last Compiled? – Interview Question of the Week #292
- Recent Execution of Stored Procedure – SQL in Sixty Seconds #118
- Full-Screen Execution Plan – SQL in Sixty Seconds #117
- Recover Crashed Query in SSMS – SQL in Sixty Seconds #116
If you like the video, please do not forget to subscribe to my youtube channel. Let me know if you have any other SSMS tip which you think help the larger community.
Reference: Pinal Dave (https://blog.sqlauthority.com)