You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have an existing db, generated schema.xml, then added new column to the db and run propel diff
In a generated migration I see getUpSQL dropping the field and getDownSQL adding new field
I think getUpSQL and getDownSQL should be swapped here
The workflow we have (same issue) is that we first modify DB in our dev system directly, and then want to roll it out to our various production environments.
The advantage of this approach is that it is quite simple: We use GUI tools like phpmyadmin to edit the DB structure, and then make sure the application runs with the new structure. In this approach, there is no need to learn the Propel-specific XML format for DB structures.
That's not an advantage, it's sloppy. Use the schema and diff set to manage the changes in your database. Review how ORMs work and why you should manage chnagesets and not modify your database directly. This is an ORM toolset.
I have an existing db, generated
schema.xml
, then added new column to the db and runpropel diff
In a generated migration I see
getUpSQL
dropping the field andgetDownSQL
adding new fieldI think
getUpSQL
andgetDownSQL
should be swapped herePropel2/src/Propel/Generator/Command/MigrationDiffCommand.php
Lines 218 to 219 in 431b8d0
Or I just use Propel in a wrong way)
The text was updated successfully, but these errors were encountered: