View | Details | Raw Unified | Return to bug 7792
Collapse All | Expand All

(-)a/installer/data/mysql/kohastructure.sql (+1 lines)
Lines 362-367 CREATE TABLE `branches` ( -- information about your libraries or branches are st Link Here
362
  `branchip` varchar(15) default NULL, -- the IP address for your library or branch
362
  `branchip` varchar(15) default NULL, -- the IP address for your library or branch
363
  `branchprinter` varchar(100) default NULL, -- unused in Koha
363
  `branchprinter` varchar(100) default NULL, -- unused in Koha
364
  `branchnotes` mediumtext, -- notes related to your library or branch
364
  `branchnotes` mediumtext, -- notes related to your library or branch
365
  PRIMARY KEY (`branchcode`),
365
  UNIQUE KEY `branchcode` (`branchcode`)
366
  UNIQUE KEY `branchcode` (`branchcode`)
366
) ENGINE=InnoDB DEFAULT CHARSET=utf8;
367
) ENGINE=InnoDB DEFAULT CHARSET=utf8;
367
368
(-)a/installer/data/mysql/updatedatabase.pl (-1 / +7 lines)
Lines 4994-4999 if ( C4::Context->preference("Version") lt TransformToNum($DBversion) ) { Link Here
4994
    SetVersion($DBversion);
4994
    SetVersion($DBversion);
4995
}
4995
}
4996
4996
4997
$DBversion = "XXX";
4998
if (C4::Context->preference("Version") < TransformToNum($DBversion)) {
4999
    $dbh->do("ALTER TABLE branches ADD PRIMARY KEY (branchcode);");
5000
    print "Upgrade to $DBversion done (redefine the field branchcode as PRIMARY KEY of branches)\n";
5001
    SetVersion ($DBversion);
5002
}
5003
4997
=head1 FUNCTIONS
5004
=head1 FUNCTIONS
4998
5005
4999
=head2 DropAllForeignKeys($table)
5006
=head2 DropAllForeignKeys($table)
5000
- 

Return to bug 7792