Getting Started With Azure Database for MySql

I thought I’d share some bits and pieces about getting started with Azure Database for MySql, the Azure platform-as-a-service (Paas) offering for the MySql relational database engine. Initially I started looking for a good sample database to use for demonstration purposes, but unfortunately either my search engine skills or my patience were lacking. However, that gave me a good opportunity to set up a new demo database from scratch!

I started out by setting up a dedicated resource group to use for my instance, and then used the Azure Portal GUI to create a new instance named mysql-20200505. I made sure to downgrade from the default General Purpose configuration to Basic, so it will only cost me about $67 a month if I leave it running instead of around $350. After the instance was created successfully I then added some connection security rules to ensure that only my IP was able to connect to it.

I then opened up MySql Workbench to connect to the server as pictured below. Of course it took me two tries to connect as I made my usual error of not including the machine name in the username field the first time around.

I quickly created a new database:


I then queried the system catalog to make sure that the database had been created and made available successfully:

The first table I decided to build was a tally table – a table of sequential numbers. I placed this in a new schema named admin, and I’ll use it to populate some of the other tables I’ll be creating in the future. I used a set-based method to generate this data by cross-joining one of the system catalog tables to itself. There are about 300 records in the catalog table in a brand new database, and so one cross join gives me 300 x 300, or 90,000 rows, which is plenty more than the 10,000 rows I want.

The only gotcha here was that I’d installed an older version of MySql from before it implemented the ROW_NUMBER() windowing function. Luckily my search engine skills had improved and I found a solution quite quickly using a local variable as below:

USE demo;



SET @row_number = 0;

    (@row_number := @row_number + 1) AS SequenceNumber
    information_schema.tables tbl1
    information_schema.tables tbl2

And now my tally table is created, populated, and ready to use in the next blog post in which I’ll begin to create some dummy data warehouse tables for my demo database.

Thanks for following along, and please let me know in the comments below if there are any particular areas of MySql you’d like me to dive into deeper!

How I Passed The AZ-900 Azure Fundamentals Exam

Recently I passed the AZ-900 Azure Fundamentals exam from Microsoft. We could have a long conversation about the pros and cons of IT certifications in general, but for me wanting to pass this exam was great motivation to learn about a number of the Azure service offerings that I haven’t yet needed to use in a professional capacity.

The exam itself is a very broad, mostly non-technical, survey of cloud computing concepts and the various Azure services that are available. For example, you need to know that IoT Hub is the Azure service that you would use to manage large numbers of Internet-of-Things (IOT) devices, but you don’t need to know how to actually configure and use it.

Resources: Since I posted about passing the exam, several people have reached out to me asking what materials I used to prepare, so I’ve listed them here:

Microsoft Azure Fundamentals Exam Ref AZ-900 book
• The official AZ-900 practice test from Measure-Up
• Tim Warner’s Azure Fundamentals Study Guide video series on YouTube
• The Azure fundamentals learning path on Microsoft Learn

Microsoft Azure Fundamentals Exam Ref AZ-900 by Jim Cheshire is the official study guide for the test. It was my number one resource, and was a bargain at only $26 from Amazon. If you read it cover-to-cover you will be well on your way to passing the exam! The official practice test from MeasureUp was hugely important too, and I may write a follow-up post to dive into more detail about how I used it effectively. It costs $120, or is discounted to $80 if you purchase it at the same time you register for the exam.

Tim Warner’s [b|t] video series on YouTube is particularly good, and as a bonus, it’s free! He is creating a separate video for each of the nearly 50 skill entries on the exam guide, and as of this writing has completed nearly half of them. Each one is a 10-15 minute treatment of what you need to know about that skill and usually includes a short demo. Highly recommended!

The Azure fundamentals learning path on Microsoft Learn is another very good free resource. It takes about 6-10 hours to complete and covers all of the objectives on the exam, many with practical exercises. Unfortunately I didn’t make completing this a high enough priority and ran out of time to finish it before the exam!

Key Concepts: Here are some of the concepts and services that either came up multiple times or that tripped me up on the practice test. Not all of these appeared on my actual exam, but that was only 34 questions drawn from a much larger pool. I’ve grouped these based on the published exam objectives:

Understand cloud concepts
• IaaS vs PaaS vs SaaS
• Public vs private vs hybrid cloud models
• CapEx vs OpEx

Understand core Azure services
• Geographies, Regions, Availability Zones, Availability Sets
• Azure Load Balance vs Azure Application Gateway vs VPN Gateway
• IoT Hub vs IoT Central
• Machine Learning Service vs Machine Learning Studio
• Azure Functions vs Azure Logic Apps
• Azure CloudShell vs PowerShell vs CLI

Understand security, privacy, compliance, and trust
• AIP vs ATP

Understand Azure pricing and support
• Developer vs Standard vs Pro Direct vs Premier Support Plans

Effort: I put around 20 hours of work into passing the exam. I’m fortunate to be able to read very quickly and to be a good test-taker, so your mileage may vary. But with a modicum of effort most existing or aspiring IT professionals should be able to pass this exam quite easily.

I hope this post helps you get started on your way to passing the AZ-900 Azure Fundamentals exam!