Skip to content

Getting Started Part 11: Create The Initial Database With Migrate

Laurent Hasson edited this page Nov 30, 2019 · 3 revisions
Previous Main Next
<-- Part 10 Main Part 12 -->

Create the TildaTutorial database using your favorite DB tool (e.g., PGAdmin, Toad, Azure Studio or DBeaver). Here we use DBeaver.

You can now run Migrate and get a Woohoo!

The logs are rich about what's going on and are essentially composed of 6 parts. The initialization, for the first time, will show some errors since the database is effectively empty. Those errors can be ignored.

The utility prompts to start the analysis and warns you about having a backup. Although the Migrate utility is designed to not be destructive (it won't drop tables or columns for example), there is always a risk for any migration that something may go wrong, so having a backup is simply a good practice. Press ‘y’ followed by enter.

A second warning will show up if you are using a superadmin account (e.g., postgres). For Dev, it’s OK to run with the “postgres” admin account, but the utility flags this as a risk. In prod, you would not use a super user account.

The analysis yields a number of migration steps for your review. Type “yes” and enter to start the migration proper. Note how so far we only have an empty schema for the TildaTutorial app. Two supporting schemas TILDA and TILDATMP are created to support the database-level runtime portion of Tilda. See The Tilda Common Helper Database Functions for example of what is provided.

Migrate also manages the necessary roles in the database for further work.

And in the end, you should get a happy Woohoo!

You can check the DB to see the new schemas and tables created.

Previous Main Next
<-- Part 10 Main Part 12 -->
Clone this wiki locally