PASS Board 2016: Update #1

PASS
Hello everyone. Just because I've moved on to the executive committee doesn't mean I'm walking away from these reports. I will continue to communicate all that I can about my role as EVP throughout the year. One of our commitments this year is providing greater insight into each of the portfolio roles, including the Executive. You’ll start to see more communications in the coming weeks of each of our roles. The last month has largely been about learning my new role. As EVP, my primary responsibilities include working closely with PASS HQ on finances and governance. Some of these responsibilities may seem tedious and mundane, but they are an essential part of ensuring that PASS delivers on its mission to provide our global community with the best professional development and networking…
Read More

The Importance of a Full Backup in SQL Server

Database Lifecycle Management, DevOps, Professional Development, SQL Server, SQL Server 2016
This is the first of 12 posts this year in support of Tim Ford's #iwanttohelp initiative. These will be completely 100 level, introductory blog posts meant to help people that are just getting started as data professionals. I'll try to cover several different topics over the year, but felt I should start with what I think is the most important, backups. It is impossible to overstate the importance of getting a good backup of your SQL Server databases. A backup is the most fundamental of protections for the information on which your business is dependent. Since SQL Server is a service, it manages it's own files. Because of this, you can't just copy the *.mdb file where your data is stored. Instead, you must run a process, usually through the…
Read More

Finding Your Query in Query Store

Azure, SQL Server 2016, T-SQL
Query Store is pretty amazing. I'm loving working with it. I think it's likely to change how query tuning will be done in the future. Lots of people are probably going to just use the reports and tools in SQL Server Management Studio. However, a pretty healthy chunk of us will start using the system views in order to programmatically access the information stored in Query Store. One of the first things you're going to want to do is track down your query. The primary views you'll want are sys.query_store_query and sys.query_store_query_text. They join together based on the query_text_id. Let's take four scenarios and see if we can retrieve the correct query. First up, an ad hoc query: SELECT e.NationalIDNumber, p.LastName, p.FirstName, a.City, bea.AddressTypeID FROM HumanResources.Employee AS e JOIN Person.BusinessEntityAddress AS…
Read More

Removing All SQL Server Query Store Data

Azure, SQL Server 2016
While setting up example code for my presentation at SQL Cruise (which is going to be a fantastic event), I realized I wanted to purge all the data from my Query Store, just for testing. I did a series of searches to try to track down the information and it just wasn't there. So, I did what anyone who can phrase a question in less than 140 characters should do, I posted a question to Twitter using the #sqlhelp hash tag. Jamey Johnston (t|b) came through... and it was right there in the documentation that I had been reading, over and over. In fact, it was in the documentation in two different places. Reading is clearly a problem for me today. Just so that you know, it's actually really easy:…
Read More

Learning R: Hitting the Books

Data Science
I've been using a series of web sites while I was starting the process of learning R. I've highlighted several of these in previous posts. While people will claim to learn better based on a single source-type, studies have found that you actually learn best by a multitude of methods. So, in addition to video instruction, web sites, guides, etc., I'm also going to read a few books to help learn R. After a lot of research, I've arrived at two that I'm starting with. The first is R In Action. I'm already on the 2nd chapter and I'm enjoying the style and approach. The other book is Using R for Introductory Statistics. I'm using this book because as I have already picked up, the real trick to learning R…
Read More

“Applies To…” in the MSDN Documentation

Azure, SQL Server 2016, T-SQL
Quick little post. I just wanted to share how happy I am with the new "THIS TOPIC APPLIES TO" infographic. An example here: I think it makes things much more clear when you're attempting to figure out what's up with some T-SQL syntax. Well done Microsoft and thank you. Side note, this only exists in documentation that has been updated recently. I first saw it in some documentation that was updated January 11, 2016. It's not there in another piece of documentation I saw that was updated October 15, 2015. Here's hoping it gets put everywhere. It works.
Read More

Restoring a Database in Azure

Azure
One of the many small things you don't have to worry about any more when working with Azure SQL Database are those pesky backups... Ha-ha-ha! Yeah, I can't keep a straight face when I type it. Microsoft takes on the role of DBA and creates backups and log backups for you when you're working in the Platform as a Service offering of Azure SQL Database. If that doesn't scare you, I'm not sure what will. However, there's good news. There are still ways for you to create your own backup (through the bacpac, I outlined it here, years ago). More good news is, Microsoft's backups actually work. Testing it out is easy. Let's walk through it once. I'm going to assume you have an Azure account on which you already…
Read More