Search Results for “execution plan”

[Video] Office Hours: 30 Minutes of Rapid-Fire (And a Little Burnination)

Videos
1 Comment
Almost all of today’s questions from https://pollgab.com/room/brento were great! Well, except two. Here’s what we covered: 00:00 Start 02:13 Andrei: What’s the appropriate response/punishment for developers who insist on storing json and xml in nvarchar(max) fields? 03:43 JustGoogleIt: What are your thoughts on Jeff Moden’s “Black Arts” Index Maintenance — GUIDs v.s. Fragmentation? How would…
Read More

[Video] Office Hours: 45 Minutes of SQL Server Q&A

Videos
3 Comments
It’s a long one, folks! I went through almost 30 of your questions from https://pollgab.com/room/brento to get your learn on:   Here’s what we covered: 00:00 Start 00:30 Jr Wannabe DBA: Hi Brent, recently you talked about linters; do you recommend any for T-SQL? I tried a few randomly from Google search, they are useless.…
Read More

How to Go Live on SQL Server 2022

SQL Server 2022
7 Comments
You’re planning to migrate to SQL Server 2022, and you want your databases to be faster after the migration. This is NOT a blog post about how to migrate – that’s the same as it’s been for a long time. Go build the new 2022 servers, and use log shipping or database mirroring to sync…
Read More

Office Hours Speed Round, Easy Text Answers Edition

Some of the questions y’all post at https://pollgab.com/room/brento have easy one-line answers. Let’s knock ’em out: George: Hi Brent, what recently has been the most challenging/surprising/new-to-you performance issue you have encountered? SQL Server 2019’s slowdowns. I spent days working on that. RoJo: Have you used Distributed AG as a way to upgrade major versions of…
Read More

[Video] Office Hours: Ask Me Anything About SQL Server

Videos
0
Y’all post and upvote questions at https://pollgab.com/room/brento, and I stream sessions on my Twitch.tv channel where I answer ’em and chat with the audience. 00:00 Start 02:09 Chad Baldwin: Hey Brent! “a friend told me” MSSQL will use an index’s stats to generate a plan, but not use the index itself. 03:25 Jeremiah Daigle: Hey…
Read More

The SQL Server Posts You Read the Most in 2022

Company News
3 Comments
Here’s what I wrote in 2022 that gathered the most views: #10: Who’s Hiring in the Database Community? February 2022 Edition – I saw the success of Hacker News’ “Who’s Hiring” monthly posts, and I blatantly stole the idea for the Microsoft data platform community. It works out well, very popular, very popular. #9: PSPO:…
Read More

[Video] Office Hours: Holiday Speed Round

Videos
0
Beep beep! Here’s a speed round of Office Hours where I rip through a dozen questions in under ten minutes. Want to see your own questions answered? Post ’em and upvote the ones you like at https://pollgab.com/room/brento. 00:00 Start 00:22 DB-A-Team: Love and appreciate your work and please don’t make fun of my question. I…
Read More

Should You Use SQL Server 2022’s GREATEST and LEAST?

SQL Server
2 Comments
If you’ve been following along with this week’s posts on DATETRUNC and STRING_SPLIT, you’re probably going to think the answer is no, but bear with me. It’s Christmas week, right? The news can’t all be bad. GREATEST and LEAST are kinda like MAX and MIN, but instead of taking multiple rows as input, they take multiple columns.…
Read More

Should You Use SQL Server 2022’s STRING_SPLIT?

T-SQL
2 Comments
SQL Server 2022 improved the STRING_SPLIT function so that it can now return lists that are guaranteed to be in order. However, that’s the only thing they improved – there’s still a critical performance problem with it. Let’s take the Stack Overflow database, Users table, put in an index on Location, and then test a…
Read More

Should You Use SQL Server 2022’s DATETRUNC?

T-SQL
10 Comments
SQL Server 2022 introduced a new T-SQL element, DATETRUNC, that truncates parts of dates. For example: SELECT DATETRUNC(year, '2017-06-01'); 1 SELECT DATETRUNC(year, '2017-06-01'); Truncates everything in that date other than the year, so it returns just 2017-01-01 00:00: You might ask, “Well, why not just use YEAR()?” That’s a good question – there are times…
Read More

Slow “Having” Query? Try Pre-Filtering.

T-SQL
11 Comments
I was helping a client with a query, and I’m going to rework the example to use the Stack Overflow database for easier storytelling. Say we need to: Find all the locations where users have logged in since a certain date, then Return the total count of people who live in those locations One way…
Read More

Join #TeamHugo and Help Fight Leukemia.

#SQLPass
If you’ve been reading this blog for a while or subscribed to my email newsletters, you’ve learned something from Hugo Kornelis. Hugo is the wildly productive and selfless guy behind the Execution Plan Reference, SQLServerFast.com, tons of SQLBits sessions, videos on YouTube, and he’s @Hugo_Kornelis. He’s unbelievably upbeat and positive. He loves what he does, and…
Read More

[Video] Office Hours: Sponsored By Black Friday Edition

Videos
2 Comments
Y’all post questions at https://pollgab.com/room/brento, upvote the ones you’d like to see me cover, and then I talk through ’em. Here’s what we covered today: 00:00 Start 00:22 CKI: Could please give me pointers how to answer the question “Do we need to create a new instance for the new application or can use the…
Read More

[Video] Office Hours: Six-Minute Speed Round

Videos
1 Comment
The morning after the Data TLV Summit in Tel Aviv, I stood out on the balcony and answered a few of your questions from https://pollgab.com/room/brento, rapid-fire style:   Here’s what we covered: 00:00 Intros 00:47 cyrpl: Hi Brent from PEI, Canada. A support person told me today that when creating a table, an ID column…
Read More