TSQLTuesday.com – Quick WordPress Setup in Azure

When I agreed to host the T-SQL Tuesday site, I wasn’t sure what to do. I thought about just putting up a static page, one I’d edit, but in some conversations with Adam Machanic, he wanted to have a few people able to manage the site. That makes sense and means I have less to do.

My first thought had been to build a SQL database, set up a web page, maybe add some logins for people, etc. Sounds great, but that can be a lot of work, and while I don’t mind some projects, I don’t want a big project that’s just a small service. Especially for data that’s really just historical logging.

When I woke up one morning and found a domain transfer request, I felt some pressure to get something up quickly. One of the great things about using domains on the web is that I could build something quick, point the domain to it, and build something else in the background, moving the domain later. There might be redirect issues, but in this case I expect most people just hit the domain, tsqltuesday.com, so I decided to focus there.

Azure Websites

I had experimented a bit with Azure websites, setting a few up, and thought this might be easy. In fact, it was really easy, so I decided to write a bit about the experience. Note, this is what the experience is like in Mar 2017. It could change quarter to quarter, so use the process and images as a rough guide.

To get started, log into your portal. If you don’t have an Azure account, google how to create one, set it up, and then come back.

Once you have an account, click New and choose .

2017-03-11 21_01_53-Web   Mobile - Microsoft Azure

From here, pick “See All” and then find WordPress.

2017-03-11 21_02_15-Untitled

Once you select WordPress, you just click Create.

2017-03-11 21_02_56-WordPress - Microsoft Azure

I tried to keep this simple, and picked these options.

2017-03-11 21_03_47-WordPress - Microsoft Azure

one thing I had to do was pick a size above the free service. This is because the free services don’t allow custom domains, and while tsqltuesday.azurewebsites.net works, it’s not as cool at tsqltuesday.com. Plus Brent had already transferred the domain to me, so I was on the hook.

Once this was done, I had the site created.

2017-03-11 21_07_42-tsqltuesday - Microsoft Azure

Once the deployment completes ,you have a blank WordPress site. You log in with your credentials and start configuring, just as you’d do on wordpress.com or with your own installations.

2017-03-11 21_09_56-WordPress › Installation

I took a few guesses on how to organize the site, but I’ll discuss those late. This is really about getting a quick site up, one for your business, for your blog, or whatever you’d like. This is my second WordPress site on Azure, and I’m amazed at how easy it is.


Posted in Blog | Tagged , , | 1 Comment

Change Approvals

Part of a developer’s or DBA’s career is getting their work released to some system where others can use the system. Some of us may do this more than others, but we all usually have some role, whether in packaging changes up or actually pushing the button that runs a script or copies files to some live server. This can be an exciting and stressful time, depending on how you feel about the quality of the work.

Releasing software often isn’t something done in a vacuum. Even in the highly agile, DevOps companies like Amazon and Facebook where developers release code many times a day, there is often some sort of approval process, whether implicit or explicit, before code goes out. Even if it’s just a peer that code reviews something, or a business person that examines a test version and pronounces it correct, another person often weighs in on our changes.

That’s not always the case, as I know in emergencies, some of us make quick decisions and change or run code that only we have examined. I’d hope that’s the exception, rather than the rule, with most database changes.

Today I’m curious. Who approves your database changes? Is there a formal process? An informal one? Does the person making the decision even understand the code or do they depend on you to have written and tested solid T-SQL?

It’s been said that the person closest to the work is often the best person to judge if it should be released, but that’s only partially true. Deploying code is often disruptive. It introduces change, which customers may or may not like. There may be good reasons to release at discrete intervals, rather than whenever the developer things things are working. This may change with heavy use of feature flags or feature toggles, but in general, code releases are interruptions and we want to limit them.

Unless something is broken, in which case, we often want the change as quick as it can be released. Does that mean we want a different change process? Let us know today.

Steve Jones

The Voice of the DBA Podcast

Listen to the MP3 Audio ( 3.0MB) podcast or subscribe to the feed at iTunes and Libsyn.

Posted in Editorial | Tagged | Leave a comment

I Hate To Send This Email

I use TrueDelta to report my car status every month. It’s a nice service, allowing car owners to see what experiences others have, and think about which models and years might be a good fit for me. I’ve tracked multiple cars with their service for the last 3-4 years, with reminders from them every quarter to update any repairs I’ve made.

Recently I got an email from them with this opening: ” We hoped never to have to send this email. A few days ago we learned that TrueDelta has joined the increasingly long list of organizations whose server security has been breached by hackers.” The email went on to note that names and passwords to taken, and that everyone needed to perform a password reset. I applaud them for including “Security breached” in the subject as well as immediately changing everyone’s passwords so old ones wouldn’t work.

I’ve been hacked at SQLServerCentral, though to our knowledge no data was stolen, merely vandalized. We haven’t ever been able to track suspected data breaches back to SSC, and I hope we never do, but I’m not naive to think that we never will. I hope we don’t, but hackers make determined efforts to gain access to data. At least we are aware of security measures, have a small staff with administrative access, and try to not allow any simple attack vectors.

Not every company does a great job at securing their data, especially from phishing attacks. There’s a spectrum of how carefully data is protected by organizations, and as we’ve seen from haveibeenpwned.com and plenty of media reports, more and more companies lose data all the time. Some of those companies notify customers (some have to), and I would guess more than a few people have had to send out emails they never expected to send. More of us will dsend those emails in the future, and we should think about that today. Is there something we can do to avoid having to send those notifications?

There probably isn’t something to ensure it never happens, but we can certainly work towards improving our security. As developers, we shouldn’t have short limits or character choices for passwords. If you wonder why, there’s a great answer at security.stackexchange. We shouldn’t be writing our own authentication schemes, but incorporating code that’s been written, vetted, and reviewed. And make sure we apply patches. Most of the security holes in software are known and patched, but without being deployed. Certainly if new patches become available, we should be able to incorporate them quickly. Above all, learn what SQL Injection is and don’t allow unvetted user input in queries, including those in hidden form fields.

Steve Jones

The Voice of the DBA Podcast

Listen to the MP3 Audio ( 4.4MB) podcast or subscribe to the feed at iTunes and Libsyn.

Posted in Editorial | Tagged , | Leave a comment

Delete an Azure SQL Database from PowerShell

Another post for me that is simple and hopefully serves as an example for people trying to get blogging as #SQLNewBloggers.

One of the things I’ve been working on is trying to get my DevOps, continuous delivery pipeline working with Azure. Part of that is a test deployment to an Azure SQL Database, which means I need to be able to update an existing database from a backup. Unfortunately, Azure SQL Database doesn’t support a restore over an existing database (yet).

That means one task I have is to remove an existing database, in order to replace it with a new database with the same name. A little work in the PoSh documentation found Remove-AzureRMSQLDatabase, which is just what I need.

To use this cmdlet, I need a connection to the Azure space first. I can do that with a credential that I get with this command. Ultimately I need to store this, but interactively this lets me get started:


This gets me an interactive login. I enter my account and password. Since I use a Live account, this won’t work in the pipeline, but it gets me going.

2017-03-10 09_00_34-Sign in to your account

From here, I can set a few variables I’ll need. I want the name of a resource group, a server, and a database. In my case, I’ll use a few variables. I call the database the “new” one, since I’ll be using an existing one that I’ll recreate from an “old” one.

2017-03-10 09_03_07-powershell - How to Login without prompt_ - Stack Overflow

From here, it’s just a question of calling the Remove-AzureRmSqlDatabase cmdlet with parameters. I do that, and get results. Here’s the call

Remove-AzureRmSqlDatabase -ServerName $server -ResourceGroupName $rgname -DatabaseName $newname

Here are the results. I’ve blacked out a few ids.

2017-03-10 09_05_16-Photos

This clears the database, and after refreshing, I can see it’s gone from my list of Azure SQL Databases.

2017-03-10 09_08_12-SQL databases - Microsoft Azure

Not much to this, but it’s part of a larger scheme, which is getting a copy of the production database and restoring it.

Posted in Blog | Tagged , , , | Leave a comment

Launching Products

Over the years I’ve seen a lot of products launched. I still remember the fanfare around Windows 95, and the efforts to make this an event of sorts, back when virtual events didn’t make sense. There have been a few Windows or SQL Server launches, some of which took place at large conferences, but quite a few were launched in different communities with small physical events. In Denver, there were a few times when Microsoft rented a hotel conference space and scheduled speakers, some from Microsoft, and some local. These would be all day events, showcasing new features, with customers talking about their experiences in previewing the product.

Just a few weeks ago, Microsoft launched Visual Studio 2017, with some fanfare, and two days of virtual events. I watched one, and hope to find some time to watch a few of the second day’s events. While I don’t necessarily learn a lot, I go get a bit excited seeing new technology and how different people use it. It’s inspiring to see demos and solutions work well on stage. I think it’s a welcome respite from the drudgery of dealing with my own or other people’s code, and the various problems it presents, as well as the various bugs and limitations of the tools and IDEs I use. It seems there’s always some devil in the details that slows me down.

However, for a short time, I get rejuvenated and excited by the new features. I want to dig in and experiment. It can be a struggle to find time, but watching someone demo a new way of working reminds me of the things I love about computers and technology. I think this is one of the reasons I love attending SQL Saturdays or other conferences and watching other presenters talk. I always see some new and interesting things that generate ideas and excitement. I’m really looking forward to SQL Bits in a few weeks (still time to register), and a few days of seeing what others have been accomplishing with SQL Server.

I also have pride when I’m a part of the company launching a product. At Redgate, we’ve had a number of SQL in the City shows, which I’ve been honored to be a part of in many cities around the US and UK. Last year we tried a streamed version, which was yet another experience, but one I hope we repeat again. And, in fact, I get to be a part of another product launch next week. We’ve already release SQL Clone, but we have a live-streaming launch coming next week. I’ll be traveling over to Cambridge and getting ready for a few presentations that will hopefully inspire you to try the product. If nothing else, check out the stream and see if we show anything that sparks an idea in your mind.

I know many of us work inside companies, and our product launches are small, to relatively few customers that are often our fellow employees. Some of you work with companies and the results of your work are visible to lots of others. No matter which environment you work in, I hope you feel the same pride and excitement I do when you release a new idea for your users to enjoy.

Steve Jones

The Voice of the DBA Podcast

Listen to the MP3 Audio ( 4.8MB) podcast or subscribe to the feed at iTunes and Libsyn.

Posted in Editorial | Tagged , , | Leave a comment

Building a Database DevOps Process at the Data Platform Summit 2017

I’m heading to India this August for the Data Platform Summit 2017. I am honored to have been selected to deliver a pre-conference seminar called “Building a Database DevOps Process”, where I’ll walk through the way in which you can include your database alongside application code and deploy it smoothly to various other environments, such as test, QA, UAT, Beta, Staging, Pre-prod, etc.


If you are going to be in Bangalore during the middle of August, register for the DPS and come see my, or another, pre con as well. There are some great ones.

This will be my first trip to India and I’m looking forward to it. Actually my whole family is looking forward, as I’ll be taking a week or so vacation before the conference to travel with them before I spend a week at work. I should be acclimated to the time change by the time the conference starts, which is good. I’ve got customer training also scheduled, so a busy August for me.

Now to get a Visa and inoculations. Hope to see you there.

Posted in Blog | Tagged , , , | 2 Comments

We are All Data Companies

I have seen more than a few people note that every company is a software company. Or that every company should be a software company because software is becoming so important. I’m not sure that’s true. My mechanic certainly uses software, and he competes well with other businesses by tracking my car, reminding me of issues, and keeping in contact through integration between his point of sale system and some sort of email management software. However, this is a small shop, probably less than 20 employees, and I’m not sure they’re ever going to be in the business of software. They are consumers, and they need support, but they aren’t in the software business. My wife’s company is similar. She needs a website, needs to schedule events and take payments, but she’s not going to develop software to help her. Nor am I going to write code, because that might be a never-ending job.

It’s easy to get out of touch and think that many larger companies need to be software companies. That might be true for some businesses, especially when they need to manage some infrastructure, but for many smaller businesses, I’m not sure that’s the case. Software is critical to small medical practices and retail stores, and service people, but only as a tool. Not as something they’d want to maintain or even customize beyond a simple look and feel.

Is that true for data? If many companies aren’t software companies, are they data companies? I think so. Data is important, and having some way to look at data and manage it becomes important for them to run their business well. My wife struggles with data, but realizes that managing her mailing list and tracking the contacts is valuable. It’s hard, and her bits are stored in disparate applications, but she recognize the value of data. The same for my mechanic. They’ve seen plenty of value in treating a string of disparate transactions from me across multiple cars as those from a single customer. They also have learned that finding software to understand me as a customer, as well as string together recommendations and past work on single vehicles allows them to provide better service.

Many companies want to track us through email, phone, or some other identification data because they realize that many people have come to expect a business to know something about us. We might not like them sharing or selling that data, but we do want to them to provide a better experience for us. I’m still surprised when there’s good integration between disparate systems, or a customer service call allows the company to recognize something about me and provide more value. I believe my kids and future generations will expect this to always be the case, shunning companies those that don’t provide customization.

I worry about data security, data privacy, data integrity, and more, but I do also think that as more companies realize that they are data companies, and data drives many of their interactions, they will see data as more valuable. What they do with that, I’m not sure, but I can only hope they start to treat our data as a valuable resource worth protecting.

Steve Jones

The Voice of the DBA Podcast

Listen to the MP3 Audio ( 4.2MB) podcast or subscribe to the feed at iTunes and Libsyn.

Posted in Editorial | Tagged | Leave a comment

Why DevOps? Employee Satisfaction

DevOps is being embraced by more and more companies, but still a minority of organizations that perform software development. There are plenty of software developers, project managers, and operational staff that are comfortable with their own process, even as they may struggle to produce software for their customers. I think DevOps is a better way to build software, and today I want to look at a benefit beyond faster releases. Today, let’s talk employee satisfaction.

The State of DevOps report shows that companies who have implemented a DevOps process have more engaged and happier employees. According to the eNPS (e Net Promoter Score), the employees are more likely to continue to work there, and recommend the company to their friends. That endorsement of the organization comes with two benefits. Employees are more productive, and they bring other good employees to work. After all, how many employees recommend someone they don’t want to work with or don’t think can do the job?

More deployments, easier deployments, the ability to get your code used by customers while you still remember how it works. These are the keys to helping employees enjoy their jobs. When employees are more engaged, and when they are satisfied with their jobs, they work in a more focused manner, trying to ensure their work produces results that help others in the company. In other words, more valuable code.

DevOps isn’t new; it’s a name given to a number of productive, effective practices that the best software developers have been following for years. The idea of DevOps is being more and more widely embraced, resulting in better software, along with happier employees.

Steve Jones

The Voice of the DBA Podcast

Listen to the MP3 Audio ( 2.8MB) podcast or subscribe to the feed at iTunes and Libsyn.

Posted in Editorial | Tagged , | Leave a comment

Using Trace Flags

At SQLServerCentral, we recently published a list of all the trace flags from Konstantin Taranov. It’s a great list, and thanks to Konstantin for compiling it. While I haven’t often used trace flags, there are some that have really helped me at various times when I needed to change SQL Server behavior. If you aren’t sure what trace flags are, Erin Stellato of SQLskills wrote a great post recently. I see trace flags as feature flags. The development team can allow us to experiment, test, and use functionality at our discretion, or ignore it.

This week, I wanted to ask how many of you are using Trace Flags right now. Do you have any running in code or set for startup on your instances? If you don’t know how to do this, we’ve got a short piece to help you.

In Erin’s post, she notes that SQLskills only recommends three trace flags (depending on version) for their customers. In general, I think that’s good advice. There is a risk with using flags, and certainly I would be wary of using without substantial testing. I do think Erin’s list is good, and you might consider using those. I also become wary about trace flags that aren’t embedded directly in code. I think these trace flags end up being hidden from anyone troubleshooting issues. After all, how many of you actually go to the Configuration Manager or the Services Applet and look for parameters?

I expect that most of you don’t run trace flags on your instances. There may be some of you that have never heard or, or used, a trace flag in your career. That’s fine, though I hope you use today to a) let us know, and b) educate yourself to ensure you know how to enable a flag you need one. If nothing else, add one to a test instance, and ensure you have the skills to actually make the change.

Steve Jones

The Voice of the DBA Podcast

Listen to the MP3 Audio ( 2.8MB) podcast or subscribe to the feed at iTunes and Libsyn.

Posted in Editorial | Tagged , | Leave a comment

SQL Bits in less than a month

I’m getting excited, and you should as well. Join me at a fantastic conference in the UK this spring. Register today and come to a training day and learn something. I might just see you there, as I’m thinking to take one or two myself.

I’ll be presenting “Including Your Database in a DevOps CI/CD Process” on Friday. I’ll be looking at how you can deal with the challenges of database code in a software development process.

There are lots of great sessions, and whether you come for 1 or 2 training days, just the Friday sessions, or on the free Saturday even, this is my favorite SQL Server conference and I’m sure you’ll find it to be an amazing event.

Posted in Blog | Tagged , , | Leave a comment