You are here

function uuid_update_6002 in Universally Unique IDentifier 7

Same name and namespace in other branches
  1. 6 uuid.install \uuid_update_6002()

Make all uuid columns unique keys instead of indexes.

File

./uuid.install, line 132
Install, update and uninstall functions for the uuid module.

Code

function uuid_update_6002() {
  $ret = array();
  foreach (uuid_schema() as $table => $schema) {
    db_drop_index($ret, $table, $table . '_uuid_idx');
    db_add_unique_key($ret, $table, $table . '_uuid_key', array(
      'uuid',
    ));
  }
  return $ret;
}