Combine Extended Events and TagWith to Monitor Entity Framework

SQL Server 2016, SQL Server 2017, T-SQL
I'm going to start with a sentence that makes a lot of people crazy; As a DBA and database developer, I love Entity Framework. That's right. Entity Framework is the bomb. It's amazing. It does wonderful stuff. Entity Framework makes the developers lives and jobs easier. It makes my life and job easier. Yes, Entity Framework will improve your job quality and reduce stress in your life. With one caveat, it gets used correctly. That's the hard part right? There is tons of technology that makes things better, if used correctly. There are all sorts of programs that make your life easier, if used correctly. Yet, all of these, used incorrectly, can make your life a hell. One nit that I've always had with Entity Framework is that it's very…
Read More

Opening a Twitch Channel, Data Wisdom

Misc
I want to let you know that I'm starting a channel on Twitch. You'll be able to see it here. I'm going to start doing regular live events on Fridays, probably around 10AM. Topics will range from query tuning, to GDPR, to Redgate, to Azure Data Studio, pretty much the same as the blog. I'll also take requests on topics and will host live Q&A periods during the sessions so you can ask about anything, whether it's part of that day's topic or not. Additionally, I intend to host live videos at events. I have two coming up in a few weeks, SQL Konferenz and SQLBits. I'll do live sessions at these events so that you can, even if you're not there, take part in them. I'll have interviews with…
Read More

Input Into Azure Data Studio

Azure
I see more and more people starting to use Azure Data Studio. As it keeps growing and expanding, it's going to become more and more a go-to tool for everyone that has to work with the Microsoft Data Platform. Wouldn't it be good to be able to provide direct feedback to the development team? Why not do that? GitHub Microsoft does a heck of a lot work with GitHub. It just so happens that the Azure Data Studio team is using it as well. In fact, they have a public Issues resource within GitHub. You can go there yourself, search out the existing issues, submit a problem, or, better still, submit a suggestion. The people working on this are clearly busting their behinds to add functionality and improve functionality. You…
Read More

All Day, Training Day at SQLBits

Azure, SQL Server 2016, SQL Server 2017, T-SQL
It's a somewhat late addition, but I have an all-day Training Day at SQLBits. It takes place on Thursday, February 28th. You can read all about it on the SQLBits web site. I want to take a moment here to expand on the information that we're going to cover. I think the abstract does a good job of conveying what we'll be doing all day, but I figured a little more detail won't hurt. Query Tuning is Hard This is the very first thing I talk about. Query tuning is hard. I've got a nearly 1,000 page book on the topic, which should give you an idea of just how much material there is to cover. With the training day I've decided to focus on the tools that Microsoft gives…
Read More

Critiquing Grant Fritchey: Circa 2008

DevOps, SQL Server
For several years, I ran a regular feature on this blog, Speaker of the Month. I attend a lot of events, so I have the opportunity to hear a lot of people talk about various topics. I decided, as an attempt to help out, to call out individuals that I thought had given a great presentation. There was no other reward beyond my attempts to promote others. In addition to that promotion and praise, I did offer criticism as well. It was never intended to be hurtful or in any way negative. I was hoping to point out people that I thought were great at presenting and provide a tip or two to make them even better. Not everyone liked it. In fact, a few people were decidedly, animatedly, against…
Read More

Get Your Learn On

PASS, SQL Server
There is one truth that I can say about technology with an absolute certainty: It's going to change. Get your learn on! Technology is going to be shifting under your feet, constantly. Even if all you ever do is work with SQL Server, on premises, on hardware, without VMs, containers, clouds or any of that foofaraw, things are going to change. Dealing With Change What's the best way to deal with change? Get your learn on! Learning all the new stuff is absolutely necessary. It's unavoidable. Even if you're not running SQL Server 2019 in production today (and very few of you should be as I write this because it's still in preview) because you're still on SQL Server 2005 (and, by the way, support ended in April of 2016,…
Read More

DevOps and Automation Will Eliminate the DBA

DevOps
I've been reading about the death of the DBA ever since I first made the jump from full time developer to full time data professional. The first time I heard it was when SQL Server 7.0 was released. Did you know that SQL Server 7.0 was self-tuning? In fact, it was so self-tuning that the DBA is a relic of the past and no one will be paid for that kind of work any more. Right. So, twenty years later, several versions of SQL Server with tons of improvement from back in the day, and I'm still working (and I hope you are too). Object databases were going to eliminate the DBA. ORM tools were going to eliminate the DBA. Then of course, NoSQL absolutely eliminated the DBA. In fact,…
Read More

PowerShell to Simulate Load

PowerShell
Gathering metrics is quite difficult if there are no queries. So, if you're working in non-production environments, but you still want to see some sort of load on the server, how can you do it? I use a simple PowerShell script to simulate load. Simulate Load I've posted a sample of the meat of the script before. It's a simple way to test a procedure. However, I've modified it to do a little more than just run the procedure forever. Here's the script: # connect to the database $SqlConnection = New-Object System.Data.SqlClient.SqlConnection $SqlConnection.ConnectionString = 'Server=WIN-8A2LQANSO51;Database=AdventureWorks2017;trusted_connection=true' # gather values $RefCmd = New-Object System.Data.SqlClient.SqlCommand $RefCmd.CommandText = "SELECT th.ReferenceOrderID, COUNT(th.ReferenceOrderID) AS RefCount FROM Production.TransactionHistory AS th GROUP BY th.ReferenceOrderID;" $RefCmd.Connection = $SqlConnection $SqlAdapter = New-Object System.Data.SqlClient.SqlDataAdapter $SqlAdapter.SelectCommand = $RefCmd $RefData = New-Object System.Data.DataSet…
Read More

Redgate Reviews 2018, Predicts 2019

Uncategorized
Our boss came to us and said, "We need one more webinar to round out the year." Well, we're just like you guys, counting down the hours until our holidays start like a short-timer in the military looking at that discharge date.  The boss wants an entertaining, engaging, informative webinar. You know, the usual stuff that Redgate always delivers. Yet, we are seeing the holiday light at the end of the work tunnel so none of us wanted to take on too much of a burden. So, we came up with a solution. We'll all work together to deliver a single webinar. A good round table discussion of all the cool stuff we've seen this year from Redgate, Microsoft, and the rest of the world of data. Plus, we'll toss…
Read More

Privacy and Protection in the Age of the GDPR

Redgate Software
We're seeing more and more GDPR-style laws coming out from various governments. With the GDPR starting to do enforcement at long last, it's pretty clear that privacy and protection is a growing thing. Add to this the fact that SQL Injection is still an issue along with all the other ways you can get hacked. Let's face it. We have to secure our servers better. SQL Census The Redgate Foundry is pretty much what it sounds like, a place to build tools. Basically, it's where pie-in-the-sky style experimentation takes place at Redgate. That's not to say that we don't also do very down-to-earth experimentation. In fact, for this whole privacy and protection thing, we're working on a number of tools. The one I want to draw your attention to right…
Read More