Redgate Summit – The Database DevOps Transformation Watch now
PASS Data Community Summit logo

PASS Data Community Summit

A hybrid conference in Seattle and online

15-18 November

Flyway Documentation

Poll

Clean

Drops all objects (tables, views, procedures, triggers, …) in the configured schemas.

The schemas are cleaned in the order specified by the schemas and defaultSchema property.

Clean

Clean is a great help in development and test. It will effectively give you a fresh start, by wiping your configured schemas completely clean. All objects (tables, views, procedures, …) will be dropped.

Needless to say: do not use against your production DB!

Limitations

Cleaning additional objects

For complicated database structures an accurate dependency graph cannot always be constructed, so not every object is cleaned. We also have objects we do not drop as they aren’t always safe to, for example users in SQL Server. To clean additional objects, you can add an afterClean callback defining drop statements, for example afterClean.sql:

DROP USER test_user

Usage

See configuration for clean specific configuration parameters.

Info