change primary key on updates table

This commit is contained in:
friendica
2013-09-09 04:55:43 -07:00
parent 25a5a5ff4d
commit 0565a6ef01
3 changed files with 12 additions and 3 deletions

View File

@@ -1,6 +1,6 @@
<?php
define( 'UPDATE_VERSION' , 1067 );
define( 'UPDATE_VERSION' , 1068 );
/**
*
@@ -775,3 +775,10 @@ ADD INDEX ( `site_access` )");
return UPDATE_FAILED;
}
function update_r1067() {
$r = q("ALTER TABLE `updates` DROP PRIMARY KEY , ADD `ud_id` INT UNSIGNED NOT NULL AUTO_INCREMENT PRIMARY KEY FIRST, ADD INDEX ( `ud_hash` ) ");
if($r)
return UPDATE_SUCCESS;
return UPDATE_FAILED;
}