]> git.mxchange.org Git - friendica.git/blobdiff - database.sql
Merge tag 'ui-improvements' into develop
[friendica.git] / database.sql
index f2c558241a0caea41409a84df988cd5173792566..cbf8933f3d24d4f9fa82014860b8bbd12e3bf5c0 100644 (file)
@@ -184,6 +184,8 @@ CREATE TABLE IF NOT EXISTS `contact` (
   `profile-id` int(11) NOT NULL DEFAULT '0' COMMENT 'which profile to display - 0 is public default',
   `bdyear` char(4) NOT NULL COMMENT 'birthday notify flag',
   `bd` date NOT NULL,
+  `notify_new_posts` TINYINT(1) NOT NULL DEFAULT '0',
+  `fetch_further_information` TINYINT(1) NOT NULL DEFAULT '0',
   PRIMARY KEY (`id`),
   KEY `uid` (`uid`),
   KEY `self` (`self`),
@@ -505,7 +507,7 @@ CREATE TABLE IF NOT EXISTS `intro` (
 
 CREATE TABLE IF NOT EXISTS `item` (
   `id` int(10) unsigned NOT NULL AUTO_INCREMENT,
-  `guid` char(64) NOT NULL,
+  `guid` char(255) NOT NULL,
   `uri` char(255) CHARACTER SET ascii NOT NULL,
   `uid` int(10) unsigned NOT NULL DEFAULT '0',
   `contact-id` int(10) unsigned NOT NULL DEFAULT '0',
@@ -562,6 +564,7 @@ CREATE TABLE IF NOT EXISTS `item` (
   `forum_mode` tinyint(1) NOT NULL DEFAULT '0',
   `mention` tinyint(1) NOT NULL DEFAULT '0',
   `last-child` tinyint(1) unsigned NOT NULL DEFAULT '1',
+  `network` char(32) NOT NULL,
   PRIMARY KEY (`id`),
   KEY `uri` (`uri`),
   KEY `uid` (`uid`),
@@ -593,6 +596,7 @@ CREATE TABLE IF NOT EXISTS `item` (
   KEY `mention` (`mention`),
   KEY `resource-id` (`resource-id`),
   KEY `event_id` (`event-id`),
+  KEY `network` (`network`),
   FULLTEXT KEY `title` (`title`),
   FULLTEXT KEY `body` (`body`),
   FULLTEXT KEY `allow_cid` (`allow_cid`),
@@ -1154,3 +1158,78 @@ CREATE TABLE IF NOT EXISTS `tag` (
   PRIMARY KEY (`iid`, `tag`),
   KEY `tag` (`tag`)
 ) ENGINE=MyISAM DEFAULT CHARSET=utf8;
+
+-- --------------------------------------------------------
+
+--
+-- Table structure for table `push_subscriber`
+--
+
+CREATE TABLE IF NOT EXISTS `push_subscriber` (
+  `id` int(11) NOT NULL AUTO_INCREMENT,
+  `uid` int(11) NOT NULL,
+  `callback_url` char(255) NOT NULL,
+  `topic` char(255) NOT NULL,
+  `nickname` char(255) NOT NULL,
+  `push` int(11) NOT NULL,
+  `last_update` datetime NOT NULL,
+  `secret` char(255) NOT NULL,
+  PRIMARY KEY (`id`)
+) ENGINE=MyISAM DEFAULT CHARSET=utf8;
+
+-- --------------------------------------------------------
+
+--
+-- Table structure for table `unique_contacts`
+--
+
+CREATE TABLE IF NOT EXISTS `unique_contacts` (
+  `id` INT NOT NULL AUTO_INCREMENT,
+  `url` CHAR(255) NOT NULL,
+  `nick` CHAR(255) NOT NULL,
+  `name` CHAR(255) NOT NULL,
+  `avatar` CHAR(255) NOT NULL,
+  PRIMARY KEY (`id`),
+  KEY `url` (`url`)
+) ENGINE=MyISAM DEFAULT CHARSET=utf8;
+
+-- --------------------------------------------------------
+
+--
+-- Table structure for table `thread`
+--
+
+CREATE TABLE IF NOT EXISTS `thread` (
+  `iid` int(10) unsigned NOT NULL DEFAULT '0',
+  `uid` int(10) unsigned NOT NULL DEFAULT '0',
+  `contact-id` int(11) unsigned NOT NULL DEFAULT '0',
+  `created` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
+  `edited` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
+  `commented` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
+  `received` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
+  `changed` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
+  `wall` tinyint(1) NOT NULL DEFAULT '0',
+  `private` tinyint(1) NOT NULL DEFAULT '0',
+  `pubmail` tinyint(1) NOT NULL DEFAULT '0',
+  `moderated` tinyint(1) NOT NULL DEFAULT '0',
+  `visible` tinyint(1) NOT NULL DEFAULT '0',
+  `spam` tinyint(1) NOT NULL DEFAULT '0',
+  `starred` tinyint(1) NOT NULL DEFAULT '0',
+  `bookmark` tinyint(1) NOT NULL DEFAULT '0',
+  `unseen` tinyint(1) NOT NULL DEFAULT '1',
+  `deleted` tinyint(1) NOT NULL DEFAULT '0',
+  `origin` tinyint(1) NOT NULL DEFAULT '0',
+  `forum_mode` tinyint(1) NOT NULL DEFAULT '0',
+  `mention` tinyint(1) NOT NULL DEFAULT '0',
+  `network` char(32) NOT NULL,
+  PRIMARY KEY (`iid`),
+  KEY `created` (`created`),
+  KEY `commented` (`commented`),
+  KEY `uid_network_commented` (`uid`,`network`,`commented`),
+  KEY `uid_network_created` (`uid`,`network`,`created`),
+  KEY `uid_contactid_commented` (`uid`,`contact-id`,`commented`),
+  KEY `uid_contactid_created` (`uid`,`contact-id`,`created`),
+  KEY `wall_private_received` (`wall`,`private`,`received`),
+  KEY `uid_created` (`uid`,`created`),
+  KEY `uid_commented` (`uid`,`commented`)
+) ENGINE=MyISAM DEFAULT CHARSET=utf8;