How Do You Export A Database in Azure Data Studio

SQL Server, SQL Server 2016, SQL Server 2017
I've been writing a bunch about Azure Data Studio. I've also been recording videos on the topic. A comment I received recently asked how to export a database from Azure Data Studio. It made me want to explore the topic of exporting a database as it relates to Azure Data Studio. Export? When we say export, what exactly do we mean. It could be as simple as exporting data to a flat file for consumption in Excel or something. It could be creating a backup. Maybe we mean creating a bacpac file. We could also be looking at creating individual scripts for objects within the database. Finally, what about a full export of the database object definitions? Any or all of these could be what the question was about. So,…
Read More

Installing Extensions to Azure Data Studio

Azure, SQL Server 2016, SQL Server 2017, T-SQL
If you're even thinking about experimenting with, let alone actively using, Azure Data Studio, you need to plan on installing a few extensions. Buck Woody has a great list that you should look through in this blog post. If you're just getting started with Azure Data Studio, I have an introduction here. Depending on the extension, this could be a simple as a mouse click. However, not all the extensions are that easy. Let's explore this just a little so when you do start using Azure Data Studio, things are easy. Extension From a Mouse Click For this bit of the blog post, we'll stick to nothing but mouse clicks, but, if you really want to bring the power within Azure Data Studio, you really need to learn keyboard shortcuts…
Read More

Query Store and a READ_ONLY Database

T-SQL, Tools
What happens in Query Store when the database itself is READ_ONLY? Yeah, I don't know. Let's find out. READ_ONLY The only way to find out how this works is to test it. So, let's write some code: [crayon-5cc05aa526626006915196/] Executing that resulted in a small glitch in the Matrix: 8:00:54 AMStarted executing query at Line 1Commands completed successfully.8:00:54 AMStarted executing query at Line 2Commands completed successfully.8:00:54 AMStarted executing query at Line 5Msg 5004, Level 16, State 6, Line 5To use ALTER DATABASE, the database must be in a writable state in which a checkpoint can be executed.Msg 5069, Level 16, State 1, Line 5ALTER DATABASE statement failed.Total execution time: 00:00:01.448 Well that's not going to work. Here's more code: [crayon-5cc05aa526638675538977/] I'll run the last query there twice, once to get it…
Read More

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

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

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

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