Commit cf871210 authored by Jonathon Duerig's avatar Jonathon Duerig

Update to change type in new_wires to conform with type in wires.

Fix typo in update 333
parent 697272e4
......@@ -2348,7 +2348,7 @@ CREATE TABLE `new_wires` (
`new_wire_id` int(11) NOT NULL auto_increment,
`cable` smallint(3) unsigned default NULL,
`len` tinyint(3) unsigned default NULL,
`type` enum('Node','Serial','Power','Dnard','Control','Trunk','OuterControl') default NULL,
`type` enum('Node','Serial','Power','Dnard','Control','Trunk','OuterControl','Unused','Management') default NULL,
`node_id1` char(32) default NULL,
`card1` tinyint(3) unsigned default NULL,
`port1` tinyint(3) unsigned default NULL,
......
......@@ -10,7 +10,7 @@ sub DoUpdate($$$)
DBQueryFatal("INSERT INTO sitevariables VALUES ".
" ('protogeni/idlecheck',NULL,'0', ".
". 'When set, do idle checks and send email about ".
" 'When set, do idle checks and send email about ".
"idle slices.',0)")
if (!TBSiteVarExists("protogeni/idlecheck"));
......
#
# Change type in new_wires table to reflect type in wires
#
use strict;
use libdb;
my $impotent = 0;
sub DoUpdate($$$)
{
my ($dbhandle, $dbname, $version) = @_;
if (!DBSlotExists("new_wires", "type")) {
DBQueryFatal("alter table new_wires add ".
" `type` enum('Node','Serial','Power','Dnard','Control','Trunk','OuterControl','Unused','Management') default NULL");
} else {
DBQueryFatal("alter table new_wires modify ".
" `type` enum('Node','Serial','Power','Dnard','Control','Trunk','OuterControl','Unused','Management') default NULL");
}
return 0;
}
1;
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment