Hello,
When working on the tables_update functions for sitemgr, I realized
that the different upgrade functions are not only executed when it
seems appropriate, but every time setup is run. For example:
$test[] = '0.9.15.003';
function sitemgr_upgrade0_9_15_003()
{
global $setup_info,$phpgw_setup;
$setup_info['sitemgr']['currentver'] = '0.9.15.004';
echo "upgrading from 0.9.15.003 to 0.9.15.004";
//insert something into database
return $setup_info['sitemgr']['currentver'];
}
$test[] = '0.9.15.004';
function sitemgr_upgrade0_9_15_004()
{
global $setup_info,$phpgw_setup;
$setup_info['sitemgr']['currentver'] = '0.9.15.005';
echo "upgrading from 0.9.15.004 to 0.9.15.005";
return $setup_info['sitemgr']['currentver'];
}
When 0.9.15.004 is installed and I upgrade to 0.9.15.005, I see both
message:
upgrading from 0.9.15.003 to 0.9.15.004
upgrading from 0.9.15.004 to 0.9.15.005
This is a great problem, since function sitemgr_upgrade0_9_15_003
changes the database in a way that is harmful when it is done
twice. So that after I upgrade to
upgrading from 0.9.15.004 to 0.9.15.005 the database is corrupted.
Is this problem known to others, or is there something wrong with the
way I use the setup functions?
Michael
_______________________________________________
Phpgroupware-developers mailing list
address@hidden
http://mail.gnu.org/mailman/listinfo/phpgroupware-developers