[Video] Office Hours: Sponsored By Black Friday Edition
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.
https://youtu.be/aEe-uz2Ikvc
How SQL Server compiles, optimizes, and executes individual queries.
573 associated posts292 primary posts
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.
https://youtu.be/aEe-uz2Ikvc
Ask questions at https://pollgab.com/room/brento and upvote the ones you'd like to see me cover.
https://youtu.be/QXn5Dc84KSU
Post your questions at https://pollgab.com/room/brento and upvote the ones you'd like to see me discuss during my live streams. This week, I took a break from working on my PASS Summit sessions in order to chat:
https://youtu.be/95e5CBDI2Ck
Some of the questions y'all post at https://pollgab.com/room/brento are pretty straightforward. Let's get 'er done. LetTheDbaHandleIt: My friend needs to track who has accessed what data. This is easy at OS and app level, but how can my friend verify that those who have direct DB access are not snooping on data inappropriately? e.g. payroll or…
Okay, I, uh, forgot to unmute the microphone for this one:
https://youtu.be/pvYdQXpOXug
On the last day of my Israel trip, I went through the highly upvoted questions from https://pollgab.com/room/brento and answered 'em, standing in front of the beach.
https://www.youtube.com/watch?v=Rc5aIuLo2tA
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:
https://youtu.be/M7h5Rm09ujY
Parameter sniffing is a notorious problem for Microsoft SQL Server because it tries to reuse execution plans, which doesn't work out well for widely varying parameters. Here's a primer for the basics about how it happens. SQL Server 2022 introduces a new feature called Parameter Sensitive Plan optimization. I'm not really sure why Microsoft capitalized…
Not all of the questions you post at https://pollgab.com/room/brento require long answers. Here's a quick speed round:
https://youtu.be/ABGL8CjAK4A
Got questions for me? Post 'em at https://pollgab.com/room/brento and upvote the ones you'd like to see me cover. I filter out the ones that are too short for video answers, and here's the latest batch:
Corrupted: Should DBCC CheckDB be run on secondary replicas in AG as well ? Is it recommended to attach corrupted database to Prod server, to check how your integrity check job will react ?
A reader posted a question for Office Hours: Hi Brent, What is your take on Hugo Kornelis's explanation of execution plan naming. As her his explanation, estimated exec plan is simply an execution plan whereas actual execution plan = execution plan+run-time stats. Do you agree that the naming is flawed and confusing? - Yourbiggestfan I…
This time on Office Hours, I let a few questions piled up at https://pollgab.com/room/brento that required in-depth answers to really do 'em justice. In particular, there was a statistics question that needed demos.
https://www.youtube.com/watch?v=d0CX1j0nKrA
Got questions for me? Post 'em at https://pollgab.com/room/brento and upvote the ones you'd like to see me cover. I filter out the ones that are too short for video answers, and here's the latest batch: Thomas Franz: When I have a very large table with no statistics (or not on a specific column in the…
Every now and then, a client says, "We want to add indexes to this third party application, but if we do, we'll lose support."
No problem - enter indexed views.
Not all of the questions you post at https://pollgab.com/room/brento are hard. Some of 'em can be answered in one line:
Q: accidentalDBA: Hi Brent, My friend is moving from two physical servers (production + failover) to VMs on the same host and SAN. His manager wants to keep log shipping as a DR solution. I advised against this as most disasters would affect both VMs equally. Am I missing something?
I wish we got a yellow bang on execution plans when SQL Server was making up an estimate out of thin air.
I'll give you an example: if you compare two columns on the same table, looking to find rows where they're equal, SQL Server has a hard-coded estimate that 10% of the rows will match.
You posted questions at https://pollgab.com/room/brento, upvoted the ones you'd like to see me cover, and I did the needful:
https://www.youtube.com/watch?v=PFjWYjZbES0
On a road trip from San Diego to Vegas, I stopped in Palm Springs and answered your highly-upvoted questions from https://pollgab.com/room/brento.
https://youtu.be/1P_1DFXy-h0
Until 2022, when a query couldn't go parallel, all we got was a really cryptic note in the execution plan properties saying NonParallelPlanReason = CouldNotGenerateValidParallelPlan.
But starting with SQL Server 2022, even when I'm running under older compatibility levels:
[crayon-6a738da757bdc508061431/]
The execution plan gives me way more details:
Some questions that come in at https://pollgab.com/room/brento have such straightforward answers that I don't need to cover them on video. It's time for a rapid-fire speed round:
Q: Uncle Buck: Is there a good way to tell if a given include column for a NC index is being used at all?