| Revision 1079,
445 bytes
checked in by bogdan2412, 2 years ago
(diff) |
|
Updated tagging backend again.
Added a column in ia_tags for a tag's parent and got rid of the string prefixes we used before.
Review URL: http://reviewboard.infoarena.ro/r/118/
|
-
Property svn:executable set to
*
|
| Line | |
|---|
| 1 | #! /usr/bin/env php |
|---|
| 2 | <?php |
|---|
| 3 | |
|---|
| 4 | require_once(dirname($argv[0]) . "/utilities.php"); |
|---|
| 5 | |
|---|
| 6 | db_connect(); |
|---|
| 7 | db_query(" |
|---|
| 8 | ALTER TABLE `ia_tags` |
|---|
| 9 | ADD COLUMN `type` ENUM('author','contest','year','round','age_group','method','algorithm','tag') NOT NULL, |
|---|
| 10 | ADD COLUMN `parent` INTEGER NOT NULL DEFAULT 0, |
|---|
| 11 | DROP INDEX `name`, |
|---|
| 12 | ADD UNIQUE INDEX `name_type` USING BTREE(`name`, `type`, `parent`) |
|---|
| 13 | "); |
|---|
| 14 | db_query('UPDATE `ia_tags` SET `type` = "tag"'); |
|---|
| 15 | |
|---|
| 16 | ?> |
|---|
Note: See
TracBrowser
for help on using the repository browser.