mirror of
https://github.com/friendica/friendica
synced 2025-04-22 17:10:11 +00:00
Change key-value table
- Make "k" as primary key - Added "updated_at"
This commit is contained in:
parent
f944a2a620
commit
7c4c409060
5 changed files with 68 additions and 21 deletions
22
database.sql
22
database.sql
|
@ -843,11 +843,10 @@ CREATE TABLE IF NOT EXISTS `intro` (
|
|||
-- TABLE key-value
|
||||
--
|
||||
CREATE TABLE IF NOT EXISTS `key-value` (
|
||||
`id` int unsigned NOT NULL auto_increment COMMENT '',
|
||||
`k` varbinary(50) NOT NULL DEFAULT '' COMMENT '',
|
||||
`k` varbinary(50) NOT NULL COMMENT '',
|
||||
`v` mediumtext COMMENT '',
|
||||
PRIMARY KEY(`id`),
|
||||
UNIQUE INDEX `k` (`k`)
|
||||
`updated_at` int unsigned NOT NULL COMMENT 'timestamp of the last update',
|
||||
PRIMARY KEY(`k`)
|
||||
) DEFAULT COLLATE utf8mb4_general_ci COMMENT='A key value storage';
|
||||
|
||||
--
|
||||
|
@ -1843,6 +1842,21 @@ CREATE TABLE IF NOT EXISTS `worker-ipc` (
|
|||
PRIMARY KEY(`key`)
|
||||
) ENGINE=MEMORY DEFAULT COLLATE utf8mb4_general_ci COMMENT='Inter process communication between the frontend and the worker';
|
||||
|
||||
--
|
||||
-- TABLE advancedcontentfilter_rules
|
||||
--
|
||||
CREATE TABLE IF NOT EXISTS `advancedcontentfilter_rules` (
|
||||
`id` int unsigned NOT NULL auto_increment COMMENT 'Auto incremented rule id',
|
||||
`uid` int unsigned NOT NULL COMMENT 'Owner user id',
|
||||
`name` varchar(255) NOT NULL COMMENT 'Rule name',
|
||||
`expression` mediumtext NOT NULL COMMENT 'Expression text',
|
||||
`serialized` mediumtext NOT NULL COMMENT 'Serialized parsed expression',
|
||||
`active` boolean NOT NULL DEFAULT '1' COMMENT 'Whether the rule is active or not',
|
||||
`created` datetime NOT NULL DEFAULT '0001-01-01 00:00:00' COMMENT 'Creation date',
|
||||
PRIMARY KEY(`id`),
|
||||
INDEX `uid_active` (`uid`,`active`)
|
||||
) DEFAULT COLLATE utf8mb4_general_ci COMMENT='Advancedcontentfilter addon rules';
|
||||
|
||||
--
|
||||
-- VIEW application-view
|
||||
--
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue