Search code examples
mysqlormpropel

Propel - propel:build-sql - Ability to add CREATE DATABASE .. IF NOT EXISTS


I'm customizing a phpUnderControl build file to use the symfony propel:build-sql functionality to generate .sql files to be loaded for every build (not every test). What I am running into is that the resulting .sql files expect the databases to exist, but as part of the build process, I would like to drop and recreate every database found in the schema.yml file to ensure a clean testing environment.

My question is, is it possible to configure propel:build-sql to behave as though I passed the --add-drop-database mysqldump flag?


Solution

  • No it's not possible. It's your job to drop/create the database before you run symfony/propel commands.