function hosting_package_update_7 in Hosting 7.4
Same name and namespace in other branches
- 6.2 package/hosting_package.install \hosting_package_update_7()
- 7.3 package/hosting_package.install \hosting_package_update_7()
Implements hook_update_N().
Turn the iid column of hosting_package_instance into a serial field
Required by Drupal 6 update.
File
- package/
hosting_package.install, line 264 - Define database schema and update functions for the package management module.
Code
function hosting_package_update_7() {
$ret = array();
db_drop_primary_key($ret, 'hosting_package_instance');
db_field_set_no_default($ret, 'hosting_package_instance', 'iid');
db_change_field($ret, 'hosting_package_instance', 'iid', 'iid', array(
'type' => 'serial',
'not null' => TRUE,
), array(
'primary key' => array(
'iid',
),
));
return $ret;
}