friend finder data structures

This commit is contained in:
Friendika 2011-03-13 21:53:39 -07:00
parent 0d161c6ef6
commit 79a6b70a26
3 changed files with 38 additions and 2 deletions

View file

@ -4,7 +4,7 @@ set_time_limit(0);
define ( 'FRIENDIKA_VERSION', '2.1.917' ); define ( 'FRIENDIKA_VERSION', '2.1.917' );
define ( 'DFRN_PROTOCOL_VERSION', '2.1' ); define ( 'DFRN_PROTOCOL_VERSION', '2.1' );
define ( 'DB_UPDATE_VERSION', 1040 ); define ( 'DB_UPDATE_VERSION', 1041 );
define ( 'EOL', "<br />\r\n" ); define ( 'EOL', "<br />\r\n" );
define ( 'ATOM_TIME', 'Y-m-d\TH:i:s\Z' ); define ( 'ATOM_TIME', 'Y-m-d\TH:i:s\Z' );

View file

@ -479,3 +479,19 @@ CREATE TABLE IF NOT EXISTS `cache` (
`v` TEXT NOT NULL, `v` TEXT NOT NULL,
`updated` DATETIME NOT NULL `updated` DATETIME NOT NULL
) ENGINE = MYISAM DEFAULT CHARSET=utf8; ) ENGINE = MYISAM DEFAULT CHARSET=utf8;
CREATE TABLE IF NOT EXISTS `fcontact` (
`id` INT UNSIGNED NOT NULL AUTO_INCREMENT PRIMARY KEY ,
`url` CHAR( 255 ) NOT NULL ,
`name` CHAR( 255 ) NOT NULL ,
`photo` CHAR( 255 ) NOT NULL
) ENGINE = MYISAM DEFAULT CHARSET=utf8;
CREATE TABLE IF NOT EXISTS `ffinder` (
`id` INT UNSIGNED NOT NULL AUTO_INCREMENT PRIMARY KEY ,
`uid` INT UNSIGNED NOT NULL ,
`cid` INT UNSIGNED NOT NULL ,
`fid` INT UNSIGNED NOT NULL
) ENGINE = MYISAM DEFAULT CHARSET=utf8;

View file

@ -326,7 +326,7 @@ function update_1033() {
`k` CHAR( 255 ) NOT NULL PRIMARY KEY , `k` CHAR( 255 ) NOT NULL PRIMARY KEY ,
`v` TEXT NOT NULL, `v` TEXT NOT NULL,
`updated` DATETIME NOT NULL `updated` DATETIME NOT NULL
) ENGINE = MYISAM DEFAULT CHARSET=utf8;"); ) ENGINE = MYISAM DEFAULT CHARSET=utf8 ");
} }
@ -377,3 +377,23 @@ function update_1038() {
function update_1039() { function update_1039() {
q("ALTER TABLE `addon` ADD `timestamp` BIGINT NOT NULL DEFAULT '0'"); q("ALTER TABLE `addon` ADD `timestamp` BIGINT NOT NULL DEFAULT '0'");
} }
function update_1040() {
q("CREATE TABLE IF NOT EXISTS `fcontact` (
`id` INT UNSIGNED NOT NULL AUTO_INCREMENT PRIMARY KEY ,
`url` CHAR( 255 ) NOT NULL ,
`name` CHAR( 255 ) NOT NULL ,
`photo` CHAR( 255 ) NOT NULL
) ENGINE = MYISAM DEFAULT CHARSET=utf8 ");
q("CREATE TABLE IF NOT EXISTS `ffinder` (
`id` INT UNSIGNED NOT NULL AUTO_INCREMENT PRIMARY KEY ,
`uid` INT UNSIGNED NOT NULL ,
`cid` INT UNSIGNED NOT NULL ,
`fid` INT UNSIGNED NOT NULL
) ENGINE = MYISAM DEFAULT CHARSET=utf8 ");
}