use executescript on migration files
This commit is contained in:
parent
08a4a2c99f
commit
44c823a1ae
@ -172,7 +172,7 @@ func (m *Migrator) Run() error {
|
||||
fmt.Printf("Running migration %d: %s\n", migration.Number, migration.Name)
|
||||
|
||||
// Execute the migration SQL
|
||||
if err := sqlitex.Execute(conn, migration.Content, nil); err != nil {
|
||||
if err := sqlitex.ExecuteScript(conn, migration.Content, nil); err != nil {
|
||||
return fmt.Errorf("failed to execute migration %d (%s): %w",
|
||||
migration.Number, migration.Name, err)
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user