aboutsummaryrefslogtreecommitdiffstats
path: root/install
diff options
context:
space:
mode:
authorfriendica <info@friendica.com>2015-01-27 20:00:43 -0800
committerfriendica <info@friendica.com>2015-01-27 20:00:43 -0800
commita2cdd1499c968c31ae1b95933231f80be5fc639b (patch)
tree231780d92f46a0f265e79fa478c3b7e7fc84d085 /install
parent0bfbe6d61d3c6250a162a29d2cdb0ec78ad02f1d (diff)
parent145b30adfc21b7f29d1431ebd1e2e0f4ebd853bf (diff)
downloadvolse-hubzilla-a2cdd1499c968c31ae1b95933231f80be5fc639b.tar.gz
volse-hubzilla-a2cdd1499c968c31ae1b95933231f80be5fc639b.tar.bz2
volse-hubzilla-a2cdd1499c968c31ae1b95933231f80be5fc639b.zip
Merge branch 'master' into tres
Conflicts: include/socgraph.php
Diffstat (limited to 'install')
-rw-r--r--install/schema_mysql.sql4
-rw-r--r--install/schema_postgres.sql2
-rw-r--r--install/update.php13
3 files changed, 17 insertions, 2 deletions
diff --git a/install/schema_mysql.sql b/install/schema_mysql.sql
index 226ea2308..ba41073f8 100644
--- a/install/schema_mysql.sql
+++ b/install/schema_mysql.sql
@@ -1532,11 +1532,13 @@ CREATE TABLE IF NOT EXISTS `xlink` (
`xlink_rating` int(11) NOT NULL DEFAULT '0',
`xlink_rating_text` TEXT NOT NULL DEFAULT '',
`xlink_updated` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
+ `xlink_static` tinyint(1) NOT NULL DEFAULT '0',
PRIMARY KEY (`xlink_id`),
KEY `xlink_xchan` (`xlink_xchan`),
KEY `xlink_link` (`xlink_link`),
KEY `xlink_updated` (`xlink_updated`),
- KEY `xlink_rating` (`xlink_rating`)
+ KEY `xlink_rating` (`xlink_rating`),
+ KEY `xlink_static` (`xlink_static`)
) ENGINE=MyISAM DEFAULT CHARSET=utf8;
-- --------------------------------------------------------
diff --git a/install/schema_postgres.sql b/install/schema_postgres.sql
index 8539e672d..2fcc7f9ba 100644
--- a/install/schema_postgres.sql
+++ b/install/schema_postgres.sql
@@ -1145,12 +1145,14 @@ CREATE TABLE "xlink" (
"xlink_rating" bigint NOT NULL DEFAULT '0',
"xlink_rating_text" TEXT NOT NULL DEFAULT '',
"xlink_updated" timestamp NOT NULL DEFAULT '0001-01-01 00:00:00',
+ "xlink_static" numeric(1) NOT NULL DEFAULT '0',
PRIMARY KEY ("xlink_id")
);
create index "xlink_xchan" on xlink ("xlink_xchan");
create index "xlink_link" on xlink ("xlink_link");
create index "xlink_updated" on xlink ("xlink_updated");
create index "xlink_rating" on xlink ("xlink_rating");
+create index "xlink_static" on xlink ("xlink_static");
CREATE TABLE "xperm" (
"xp_id" serial NOT NULL,
"xp_client" varchar( 20 ) NOT NULL DEFAULT '',
diff --git a/install/update.php b/install/update.php
index 8cd25f1bf..346b2c25a 100644
--- a/install/update.php
+++ b/install/update.php
@@ -1,6 +1,6 @@
<?php
-define( 'UPDATE_VERSION' , 1134 );
+define( 'UPDATE_VERSION' , 1135 );
/**
*
@@ -1537,3 +1537,14 @@ function update_r1133() {
return UPDATE_FAILED;
}
+
+function update_r1134() {
+ if(ACTIVE_DBTYPE == DBTYPE_POSTGRES) {
+ $r = q("ALTER TABLE xlink ADD xlink_static numeric(1) NOT NULL DEFAULT '0', create index xlink_static on xlink ( \"xlink_static\" ) ");
+ }
+ else
+ $r = q("ALTER TABLE xlink ADD xlink_static TINYINT( 1 ) NOT NULL DEFAULT '0', ADD INDEX ( xlink_static ) ");
+ if($r)
+ return UPDATE_SUCCESS;
+ return UPDATE_FAILED;
+} \ No newline at end of file