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

This documentation is deprecated. The new documentation can now be found on documentation.red-gate.com

Poll

Default Schema

Description

The default schema managed by Flyway. This schema will be the one containing the schema history table. If not specified in schemas, Flyway will automatically attempt to create and clean this schema first.

This schema will also be the default for the database connection (provided the database supports this concept).

Default

If schemas is specified, the first schema in that list. Otherwise, the database’s default schema.

Usage

Commandline

./flyway -defaultSchema="schema2" info

Configuration File

flyway.defaultSchema=schema2

Environment Variable

FLYWAY_DEFAULT_SCHEMA=schema2

API

Flyway.configure()
    .defaultSchema("schema2")
    .load()

Gradle

flyway {
    defaultSchema = 'schema2'
}

Maven

<configuration>
    <defaultSchema>schema2</defaultSchema>
</configuration>