mirror of
https://git.code.sf.net/p/seeddms/code
synced 2024-11-26 07:22:11 +00:00
add reference from tblUsers:homefolder to tblFolders:id
This commit is contained in:
parent
1e17c393bb
commit
0342e2a89d
|
@ -65,9 +65,10 @@ CREATE TABLE `tblUsers` (
|
|||
`loginfailures` tinyint(4) NOT NULL default '0',
|
||||
`disabled` smallint(1) NOT NULL default '0',
|
||||
`quota` bigint,
|
||||
`homefolder` int(11) default '0',
|
||||
`homefolder` int(11) default NULL,
|
||||
PRIMARY KEY (`id`),
|
||||
UNIQUE (`login`)
|
||||
UNIQUE (`login`),
|
||||
CONSTRAINT `tblUsers_homefolder` FOREIGN KEY (`homefolder`) REFERENCES `tblFolders` (`id`)
|
||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8;
|
||||
|
||||
-- --------------------------------------------------------
|
||||
|
|
|
@ -62,7 +62,7 @@ CREATE TABLE `tblUsers` (
|
|||
`loginfailures` INTEGER NOT NULL default '0',
|
||||
`disabled` INTEGER NOT NULL default '0',
|
||||
`quota` INTEGER,
|
||||
`homefolder` INTEGER default '0',
|
||||
`homefolder` INTEGER default NULL REFERENCES `tblFolders` (`id`),
|
||||
UNIQUE (`login`)
|
||||
);
|
||||
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
BEGIN;
|
||||
|
||||
ALTER TABLE tblUsers ADD COLUMN `homefolder` INTEGER DEFAULT 0;
|
||||
ALTER TABLE tblUsers ADD COLUMN `homefolder` INTEGER DEFAULT NULL REFERENCES `tblFolders` (`id`);
|
||||
|
||||
UPDATE tblVersion set major=5, minor=0, subminor=0;
|
||||
|
||||
|
|
|
@ -1,6 +1,7 @@
|
|||
START TRANSACTION;
|
||||
|
||||
ALTER TABLE tblUsers ADD COLUMN `homefolder` INTEGER DEFAULT 0;
|
||||
ALTER TABLE `tblUsers` ADD COLUMN `homefolder` INTEGER DEFAULT NULL;
|
||||
ALTER TABLE `tblUsers` ADD CONSTRAINT `tblUsers_homefolder` FOREIGN KEY (`homefolder`) REFERENCES `tblFolders` (`id`);
|
||||
|
||||
UPDATE tblVersion set major=5, minor=0, subminor=0;
|
||||
|
||||
|
|
Loading…
Reference in New Issue
Block a user