I read Brent’s first look at SSMS and Copilot in there. He didn’t have a great opinion of the tool, especially comparing it to Gemini or Claude. I haven’t tested this yet, mostly because I’ve got other stuff going on, but I decided to take his prompt and the code and drop it into the dedicated Copilot App on my Windows 11 laptop.
This is part of a series of experiments with AI systems.
I have a button that starts Copilot, so I pressed it and put in this prompt:
This was copied from Brent’s post, and then his code copied and dropped in.
I was curious to see if this worked.
My Results
I thought my results were better. The first part of the response is shown below. Copilot sees the scalar function as a problem and rewrites things. I don’t love that this is just the query and not the CREATE OR ALTER PROC part, but still.
Below this, it notes that I should test indexes and gives me the ones it would recommend. Then it goes into the fact that order by desc can be problematic. It also has a TOP 1 recommendation for the first query.
The rest of the response is OK, and gets into some general things that might help me go past the recommendations.
The prompting matters, as if I click on the “what are more perf opt techniques” I get a lot of generic stuff.
Is AI going to make you a better DBA or developer? Maybe. It will give you things to think about, but you need to test them. You might even ask a GenAI tool for help on that. I did and got this:
And below, some more steps.
Not bad, and likely what a lot of people do, though perhaps not with #5, in which HammerDB is suggested to run this proc.
Learn to use GenAI tools, learn where they help (And save time) and where they can’t be trusted. That’s likely an ongoing battle for most of us, but these tools can help us be more productive.