mirror of
https://codeberg.org/streams/streams.git
synced 2024-09-20 02:55:13 +00:00
db schema change to add tags to content sources
This commit is contained in:
parent
5e458491f1
commit
bd2f11ed8b
4 changed files with 14 additions and 3 deletions
2
boot.php
2
boot.php
|
@ -49,7 +49,7 @@ define ( 'PLATFORM_NAME', 'hubzilla' );
|
||||||
define ( 'STD_VERSION', '1.4.4' );
|
define ( 'STD_VERSION', '1.4.4' );
|
||||||
define ( 'ZOT_REVISION', 1 );
|
define ( 'ZOT_REVISION', 1 );
|
||||||
|
|
||||||
define ( 'DB_UPDATE_VERSION', 1166 );
|
define ( 'DB_UPDATE_VERSION', 1167 );
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
|
@ -1181,6 +1181,7 @@ CREATE TABLE IF NOT EXISTS `source` (
|
||||||
`src_channel_xchan` char(255) NOT NULL DEFAULT '',
|
`src_channel_xchan` char(255) NOT NULL DEFAULT '',
|
||||||
`src_xchan` char(255) NOT NULL DEFAULT '',
|
`src_xchan` char(255) NOT NULL DEFAULT '',
|
||||||
`src_patt` mediumtext NOT NULL,
|
`src_patt` mediumtext NOT NULL,
|
||||||
|
`src_tag` mediumtext NOT NULL,
|
||||||
PRIMARY KEY (`src_id`),
|
PRIMARY KEY (`src_id`),
|
||||||
KEY `src_channel_id` (`src_channel_id`),
|
KEY `src_channel_id` (`src_channel_id`),
|
||||||
KEY `src_channel_xchan` (`src_channel_xchan`),
|
KEY `src_channel_xchan` (`src_channel_xchan`),
|
||||||
|
|
|
@ -1166,7 +1166,8 @@ CREATE TABLE "source" (
|
||||||
"src_channel_id" bigint NOT NULL DEFAULT '0',
|
"src_channel_id" bigint NOT NULL DEFAULT '0',
|
||||||
"src_channel_xchan" text NOT NULL DEFAULT '',
|
"src_channel_xchan" text NOT NULL DEFAULT '',
|
||||||
"src_xchan" text NOT NULL DEFAULT '',
|
"src_xchan" text NOT NULL DEFAULT '',
|
||||||
"src_patt" text NOT NULL,
|
"src_patt" text NOT NULL DEFAULT '',
|
||||||
|
"src_tag" text NOT NULL DEFAULT '',
|
||||||
PRIMARY KEY ("src_id")
|
PRIMARY KEY ("src_id")
|
||||||
);
|
);
|
||||||
create index "src_channel_id" on "source" ("src_channel_id");
|
create index "src_channel_id" on "source" ("src_channel_id");
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
<?php
|
<?php
|
||||||
|
|
||||||
define( 'UPDATE_VERSION' , 1166 );
|
define( 'UPDATE_VERSION' , 1167 );
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
|
@ -2071,3 +2071,12 @@ function update_r1165() {
|
||||||
return UPDATE_FAILED;
|
return UPDATE_FAILED;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
function update_r1166() {
|
||||||
|
|
||||||
|
$r = q("alter table source add src_tag text not null default '' ");
|
||||||
|
if($r)
|
||||||
|
return UPDATE_SUCCESS;
|
||||||
|
return UPDATE_FAILED;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue