Database Fundamentals #6: Create a Table with the SSMS GUI

Database Fundamentals
The whole idea behind databases is to store information, data, in order to look at it later. The place where that data is going to be kept is referred to as a table. A table consists of columns and each column can be defined to store a variety of specific kinds of data. You can make small tables or large ones. The columns on the tables can be made so that they have to have data in them or they can be empty. The choices are yours to make, but you need to know how to set tables up appropriately . In addition to tables, we're going to start learning about columns. Columns can be very generic in nature, supporting all sorts of different kinds of data, or they can be…
Read More

SQL Cruise: Alaska 2017

Professional Development
We're weeks away from another SQL Cruise. If you've never heard of this before, follow the link to read more. There you'll also find testimonials and suggestions on how to sell SQL Cruise to your boss. I'm going to leave selling it to your boss to you. I want you to consider this. Class Time I'm extremely honored to once more act as one of the Technical Leads. When you look at the people I'm working with, Argenis Fernandez, Andrew Kelly, Allen White and Bob Ward (SQUEEE!), you can understand why I feel this way. I'm as grateful as I can be to Tim Ford for putting faith in me to let me stand next to these wonderful people. I'll do everything I can to prove myself worthy. That means…
Read More

Database Fundamentals #5: Database Properties

Database Fundamentals
Don’t let the ease of creating databases lull you into a false sense of security. They actually can be very complicated. You can modify and individualize their behavior within your server so that different databases behave in radically different ways. The best way to see all the different manipulations you can make, open the New Database window by right clicking on the Databases folder within the Object Explorer window, assuming you’re already connected to the server. Don’t bother typing anything into the first page. Click on the Options tab on the left side of the window. You’ll see a screen that should look very similar to this: Don’t worry. We won’t be talking about all the possible settings on this page. Instead we’ll focus on a few that are extremely…
Read More

The Choices We Make

DevOps, Professional Development
If you keep your head up and look around you'll see the choices people make all the time. I saw a recent example online in this story about two experiences, shopping at Home Depot vs. Lowes (very minor NSFW warning due to language). I don't want to get into a debate about the two stores. That's not the point. The point is, we all have two sets of priorities that we have to serve. The first set of priorities are the ones immediate to us, the rules and regulations we create and enforce around our jobs. The second set of priorities are the ones that are at least a step removed from us, the service and services we supply to our "customers". Make no mistake, we're all serving customers to…
Read More

Gratitude

PASS
I want to take a moment to thank a few people for being amazing. First up, Thomas LaRock is wrapping up his tenure on the PASS Board this year. He has one more in-person meeting at Summit 2017 and then he's basically done. I followed Tom to karaoke during my 2nd PASS Summit and have been following him around ever since. I'm honored to count him as a friend. Tom, you set an impossibly high bar. Thank you for everything you've done for me and for this community. Second, Denise McInerney is also completing her time on the PASS Board this year. Denise has been a fixture in the leadership of PASS ever since I first volunteered. I had no idea just how much guidance and advice and flat out…
Read More

I Love Entity Framework

DevOps
I love Entity Framework. I also like (not love) nHibernate. That's right, as a DBA and data professional, I'm telling you I love Object/Relational Mapping tools (ORM). I think this is a technology set that the DBA needs to more tightly embrace. Let me tell you why. Most of the Queries I know that the biggest pushback against Entity Framework (EF) and it's fellow ORM tools is that they generate crap code. I know this to be true. I've seen it. ORM tools can, and do, generate seriously poor T-SQL. That's not to mention the N+1 problem and a few others. However, as you see from the article in that link, these problems and how to avoid them are very well defined. You don't have to suffer from the issues.…
Read More

Database Fundamentals #4: Create a Database

Database Fundamentals, TSQL
SQL Server provides multiple ways to perform most functions. In order to maximize your understanding of how SQL Server works and have as many different mechanisms as possible for getting work done, you’ll use the GUI and TSQL to learn how to create and drop databases. You can then use whichever mechanism works best for you at the moment. Using  each method, we’ll first create a database using the least amount of work possible, just so you can see how easy it is create a database. We’ll go over how to remove databases from the system, getting rid of the database you just created. From there we’ll drill down to create another database, exploring some of the different mechanisms you can use to change how databases get created. Then we’ll…
Read More

Database Fundamentals #3: What’s In a Database?

Database Fundamentals
It’s worth noting that a lot of people will never need to create their own database. You may never create your own tables or other data structures either. You may only ever run backups and restores and manipulate the security on the system and let application installs create databases for you. That’s completely understandable and perfectly in line with the needs of many businesses and many accidental DBAs. However, it's a good idea to understand what this stuff is and how it works as part of understanding SQL Server. A Database Is Actually Files You need to store information that you want to be able to retrieve later. It’s necessary that you organize that information. If you were working with a word processing program, you store different documents in different…
Read More

The Three T’s of Backups

TSQL
I just read several more horror stories that include, among other things, failed backups. I've said it before (at volume, extreme volume), and evidently I have to say it again. Simply creating a backup file is not enough to ensure the protection of your information. In order to attempt to reinforce the importance of this idea, I'm going to introduce a new concept. Maybe it'll help. I'm calling it "The Three T's of Backups." Take 'Em First, and most important, you have to Take backups. That's your first "T". No, disk redundancy through RAID or a SAN or some other setup is not adequate to protect your information. You must take backups. They have to be created and they have to be run regularly. You absolutely should automate this. Test…
Read More