Initialize-EdFiDatabaseWithDbDeploy

Description

Initialize a database and apply migrations

Syntax

Initialize-EdFiDatabaseWithDbDeploy [[-engine] <String>] [-database] <String> [-csb] <DbConnectionStringBuilder> [-filePaths]
<String[]> [[-subTypeNames] <String[]>] [-dropDatabase] [[-createByRestoringBackup] <String>] [[-msSqlBackupPath] <String>]
[[-databaseTimeoutInSeconds] <Int32>] [<CommonParameters>]

Parameters

Name

Alias

Description

Required?

Pipeline Input

Default Value

engine



false

false

SQLServer

database


The database type to use when loading

true

false


csb


A Connection String Builder object for the database to build

true

false


filePaths


Array of paths to sql scripts and extension directories

true

false


subTypeNames


Scripts with these SubType names should be included. These should be
"normalized" aka contain no spaces.

false

false


dropDatabase

transient

The database is "transient" - that is, it's dropped if it already exists, and
it isn't backed up. By default, all databases are considered "persistent". That
is, not dropped if they already exists, but migrated instead, and backed up
before migrations are applied.

false

false

False

createByRestoringBackup


Instead of creating the database from scratch, use this backup file. After the
backup is restored, the database will be synced normally. Note: The backup file
must have a dbo.DeployJournal like the module expects.

false

false


msSqlBackupPath


A location to store backups of databases before they are dropped or migrated.
If this is not provided, the default backup path on the SQL server is used.

false

false


databaseTimeoutInSeconds



false

false

60