Beginning Database Migrations with Flyway | #DataAcademy | #BinduKumar

preview_player
Показать описание
In my previous video I explained the difference between Data Migration & Database Migrations. I made a reference to Flyway as a utility that can be used for Database Migrations. In case you haven't see the previous video, the link is below.

In this video, we will learn how to get started with Database Migrations using Flyway.
We are going to do the following -

- Download Flyway
- Setup a fresh Postgres database using Docker
- Download sample migrations from GIT Repo
- Understand Versioned vs. Repeatable Migrations
- Run Flyway Migrate command
- Review schema history and File checksum concept

IMPORTANT LINKS:

COMMANDS USED:

Command to run Postgres in Docker
docker run -i -t -d -p 5432:5432 --name some-postgres -e POSTGRES_PASSWORD=mysecretpassword -d postgres

Flyway commands
Check Flyway Config - "flyway info - X"
Validate migrations - "flyway validate"
Run Migrations - "flyway migrate"

If you like this video, please remember to Like this video, share it with friends & colleagues and please do subscribe

Рекомендации по теме
Комментарии
Автор

It was very useful and well explained Sir.

gayathrireddy
Автор

Can we create a database using flyway? And after that I want to create the tables. My application is multitenant configured to single database per tenant strategy . so I want to automate the process as part of onboarding the tenant I can create it's database and tables.

subhajitmondal
Автор

Hi sir I need help in migration part, unexpectedly I delete the script file in flyway, could you please help me how to solve that

anjiallakonda