If you want to change the database schema, introducing new tables or columns, or changing the current ones, please follow this procedure
- Write the necessary SQL statements, in the safest possible way (do not assume a specific database version or implementation)
- Execute them locally in the database you're currently using for development
- Execute the test scripts to check that they don't break the current functionalities
- If you're happy with them, add them to the new update script for the next release, in pub/phpeace/update.php, so that the changes will be applied to all existing installations
- Write the code and the queries so that they can be executed more than once without screwing the schema up
- Execute dev/scripts/phdb.sh to recreate dbschema.sql and init.sql based on your installation
- Compare your local dbschema.sql and init.sql with the ones in the subversion repository, to check that the differences are what you expect to see
- Commit the update script, install/dbschema.sql, install/init.sql
