Flyway Tips: Automation Assistance in Flyway Desktop

I was chatting with the product managers at Flyway and one asked me whether I’d seen the new tab for Automation in Flyway Desktop. I hadn’t and decided to take a quick look at how this works and what’s useful. This post looks at the new feature.

Tl;Dr this is a good way to start learning how to move to a more DevOps, automated way of deploying changes.

I’ve been working with Flyway and Flyway Desktop for work more and more as we transition from older SSMS plugins to the standalone tool. This series looks at some tips I’ve gotten along the way.

Working with Flyway Desktop

For a lot of customers, it’s not too hard to setup a project and start to capture code in a Git repo. However, adding in automation gets challenging for many, especially as the docs are hard to understand if you don’t already have some knowledge. I find that CI/CD is a bit of a chicken and egg challenge as we try to learn to get better, but knowing what to learn and do requires knowledge.

Which we don’t have.

In any case, I’ve taken an existing Flyway project where I am capturing some code. You can see the project below, with objects on the right. The database and the repo have the same object code and are in sync.

2025-11_line0127

Let’s add a few new objects to this database in SSMS. You can see below I’m adding a new table and altering a proc. I’m also refactoring slightly to not keep the old style join convention in my proc as I add a new join.

2025-11_line0129

Once I do this, in Flyway Desktop (FWD), I see my changes. I’ll save these to the repo and then generate a migration script. I won’t show that as it’s not important.

2025-11_line0130

Once I’ve done this, I know I want to deploy code. If I go to Migrations, I can see I have these two scripts ready to go to QA, and I can deploy them with FWD manually. However, I don’t want to do that.

2025-11_line0131

I want some automation. How does FWD make that easy? Let’s see.

The Automation Tab

There’s a new tab on the left, which is the Automation tab.  I’ve expanded the left menu out and you can see it, but it’s a lightning bolt, which I might never have noticed (hence this post).

2025-11_line0132

If I click this, I get a little explanation at the top, a few links, and then some CLI based code. This last part is the important part of what I need to move to CI/CD.

2025-11_line0133

If you look at the code closely, you’ll see some placeholders in angle brackets for the environments I need. The code looks like this:

2025-11_line0134

Above this, there are two drop downs where I can select my build and target environments. Build is the CI portion, and it’s a good idea to have a place to build code separate from QA. This lets me validate things, and more importantly, run some code analysis checks, summarize changes, and detect drift.

I’ve expanded the Build drop down below and you can see I have my environments listed, and I can also manage them from here. There is also an Environments tab on the left menu just above Automate Deployments that looks like a database icon.

2025-11_line0135

Once I select an environment, the code changes to reflect this. That makes things easier to automate as I can take these commands and drop them into a task in my CI/CD tool.Note in the image below that I’ve selected NWInt and the code shows target2. The code needs the ID (or PK) of the environment, but the display name I entered is shown in the drop down. Trust me, these match.

2025-11_line0136

I’ll also select a target and then open up a CLI to run the first item on line 5. I did have to auth, but this runs successfully. No doc checks, no experimenting, the command ran.

2025-12_0116

I’ve never saved any snapshots and so the drift doesn’t work right away, but I’ll get the dryrun script. When I run this, I get a summary from the CLI.

2025-12_0120

Then I can see the report (see above output for the path at the end. When this opens, on the Dry Run tab, I see my scripts.

2025-12_0121

Note, I did use the drop downs in FWD to select the environments I need for this.

Very cool.

Summary

One of the challenges with using Flyway is that there are a lot of settings, options, and more that one must learn to take advantage of the solution. Our docs continue to improve, but even for someone that has been using Flyway for a few years, I have to constantly check out things work. Plus, the teams are adding features on a regular basis, so it can get confusing to learn the new things.

This automation tab is really helpful to shortcut some of the things I need for the various environments in my project. I’m going to start using some of this in a new project, and so should you.

Flyway can do much more, and for smoother automation, check out Flyway Enterprise.

Flyway is an incredible way of deploying changes from one database to another, and now includes both migration-based and state-based deployments. You get the flexibility you need to control database changes in your environment. If you’ve never used it, give it a try today. It works for SQL Server, Oracle, PostgreSQL and nearly 50 other platforms.

Video Walkthrough

 

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

How Important Are Real Time Decisions?

Imagine a perfect world? I have an AI agent that knows my business well. It’s getting real time input from sales, from customers, it makes amazing decisions. We get a large order? We need to ramp up production of our widgets. We have an order pipeline of xx widgets and we know over time that yy% will close. Let’s place a larger order with a supplier overseas.

The next day, we have an election and tariffs are announced on imported parts. We react immediately, cancel the order, start the process to expand a local factory. We place ads to hire workers and order equipment. Things are looking good for our business and our factory will be up and running in a few months.

The next week we find out the tariffs weren’t really being enforced, so they’re paused. Our AI agent re-places our large order for imported parts and tried to cancel the factory expansion. Of course, it calculates the costs of both sides before deciding, and perhaps consults with me on other uses of our local factory.

How many times can we do this? Or rather, how many times would we let an AI agent keep adjusting our business?

To be fair, humans might do the same thing and over-react, but mostly we become hesitant with unexpected news. That slowness can be an asset. We often need time to think and come to a decision. Lots of our decisions aren’t always based on hard facts, and a lot of business isn’t necessarily fact driven either. We often put our thumb on the scales when making decisions because there isn’t a clear path based on just data.

Things can get worse when we collaborate. I used to run real-time reports for an importing company, and we found that executives would print a report, get busy, and after minutes (or hours), discuss the report with someone in a department. However, their numbers rarely matched because the reports were printed at different times. At first they lost trust in the system because the same report on the same day had different numbers. Even when we added a “print” or an “as of” time, the reports were too annoying to users to be helpful because the numbers didn’t match.

Real time isn’t what most of us want. Except in the Olympics. There we want the photo finish right away.

But not in all sports. A review is good. In the NFL, I’ve come to like instant reply. It’s gotten better/faster and often gives us the right answer. Not always, but often. It’s better, arguably, then just real-time humans.

Real-time decisions and reactions can be good in some cases. Adjusting machinery, vehicles, electricity, etc. where we need too-quick-for-humans decisions based on data is a good place for real time data. Lots of business decisions we make aren’t the places where we really need real-time insights. Our human brains just don’t work that fast.

Steve Jones

Listen to the podcast at Libsyn, Spotify, or iTunes.

Note, podcasts are only available for a limited time online.

Posted in Editorial | Tagged | 3 Comments

The Book of Redgate: What Our Staff Says

This image is from 2010, and it goes along with my last post of what our Customers Say about us. However, this is what our employees said about the company.

2025-10_line0105

At this point we would have been around a 200 person company, mostly in the UK. It’s a great list of words, and if I were looking for a new employer, this type of work cloud might get me interested in applying.

Redgate has often felt like an extended family, where we care about each other, we’re bonded, and we’re working together to get through life. We disagree and bicker at times, but we love each other.

We’re now closer to a 600 person company, and I don’t know that all of us, or even most of us, feel the same ways, but I’d like to think most people still think this is a great place to work.

I do.

I have a copy of the Book of Redgate from 2010. This was a book we produced internally about the company after 10 years in existence. At that time, I’d been there for about 3 years, and it was interesting to learn a some things about the company. This series of posts looks back at the Book of Redgate 15 years later.

Posted in Blog | Tagged , , | Leave a comment

PASS Keynote Shots

Rodney Kidd took some great shots of the keynote and published an album here: https://www.flickr.com/photos/127113040@N04/albums/72177720330695911

A few of my favorites:

Here’s one of the 8 ball and keynote (and I’m enjoying myself)

RG Keynote 20251119 069_fr//embedr.flickr.com/assets/client-code.js

This is a great shot of the audience

RG Keynote 20251119 077_fr//embedr.flickr.com/assets/client-code.js

Am I confused?

RG Keynote 20251119 127_fr//embedr.flickr.com/assets/client-code.js

A nice shot of the crew at the end, Grant obviously having fun.

RG Keynote 20251119 295_fr//embedr.flickr.com/assets/client-code.js

And a nice shot of my chatting with Tim at the end.

RG Keynote 20251119 302_fr//embedr.flickr.com/assets/client-code.js

Posted in Blog | Tagged , , | Leave a comment