You are here

function og_vocab_install in OG Vocabulary 5

Same name and namespace in other branches
  1. 6 og_vocab.install \og_vocab_install()

File

./og_vocab.install, line 3

Code

function og_vocab_install() {
  switch ($GLOBALS['db_type']) {
    case 'mysql':
    case 'mysqli':
      db_query("CREATE TABLE {og_vocab} (\n            nid INT NOT NULL DEFAULT 0,\n            vid INT NOT NULL DEFAULT 0,\n            KEY `nid` (`nid`)\n          )\n          /*!40100 DEFAULT CHARACTER SET utf8 */ COMMENT = 'relate group nodes to vocabularies';");

      // Update 1
      db_query("UPDATE {system} SET weight = %d WHERE name = '%s'", 5, 'og_vocab');
  }
}