Perform a schema check before merge

ceardach - March 1, 2009 - 14:04
Project:Database Scripts
Version:6.x-2.x-dev
Component:Code
Category:task
Priority:minor
Assigned:ceardach
Status:active
Description

If CCK content types haven't been imported, and update.php run, then the last-merge and production schema will be too different to perform an accurate merge, causing everything to conflict and a big mess. To save the user time, the schema should be checked against development to ensure they match before proceeding with the merge.

#1

ceardach - March 1, 2009 - 14:06

It also may be possible to put columns in the correct order when using AWK.

#2

ceardach - March 3, 2009 - 02:35
Priority:normal» minor

Lowering priority due to new method of handling CCK fields. From the documentation:

Prevent CCK fields from unnecessarily changing the content type's table schema by forcing all fields to use their own table. Create a dummy content type (perhaps called field_holder) that will be used for no other purpose, and set permissions on that content type so no one can create any nodes of that type. Then, add every field to that content type as an 'existing field'.

Whenever you add a new field, also add that field to this dummy content type. This will force all fields to store their data in their own table, and allow you to create and delete fields during development and merge those changes with production much easier.
The fields in core for Drupal 7 will be storing their data in individual tables.

 
 

Drupal is a registered trademark of Dries Buytaert.