diff --git a/sqlite/external_servers_preferences.sql b/sqlite/external_servers_preferences.sql index 922ec40..83944f5 100644 --- a/sqlite/external_servers_preferences.sql +++ b/sqlite/external_servers_preferences.sql @@ -1,7 +1,7 @@ -- external_servers_preferences definition CREATE TABLE external_servers_preferences ( - id INTEGER NOT NULL, + id INTEGER NOT NULL PRIMARY KEY, external_servers BLOB NOT NULL, external_servers_limit TEXT NOT NULL, CONSTRAINT external_servers_preferences_FK FOREIGN KEY (id) REFERENCES users(id) ON DELETE CASCADE ON UPDATE CASCADE diff --git a/sqlite/external_servers_privacy_preferences.sql b/sqlite/external_servers_privacy_preferences.sql index 9d6b558..9ea5a44 100644 --- a/sqlite/external_servers_privacy_preferences.sql +++ b/sqlite/external_servers_privacy_preferences.sql @@ -1,7 +1,7 @@ -- external_servers_privacy_preferences definition CREATE TABLE external_servers_privacy_preferences ( - id INTEGER NOT NULL, + id INTEGER NOT NULL PRIMARY KEY, discovery BLOB NOT NULL, discovery_user_limit TEXT NOT NULL, discovery_server_limit TEXT NOT NULL, diff --git a/sqlite/notification_preferences.sql b/sqlite/notification_preferences.sql index 766489e..36ab5d7 100644 --- a/sqlite/notification_preferences.sql +++ b/sqlite/notification_preferences.sql @@ -1,7 +1,7 @@ -- notification_preferences definition CREATE TABLE notification_preferences ( - id INTEGER NOT NULL, + id INTEGER NOT NULL PRIMARY KEY, lock_details INTEGER DEFAULT 0 NOT NULL, do_not_disturb INTEGER DEFAULT 0 NOT NULL, CONSTRAINT notification_preferences_FK FOREIGN KEY (id) REFERENCES users(id) ON DELETE CASCADE ON UPDATE CASCADE diff --git a/sqlite/privacy_preferences.sql b/sqlite/privacy_preferences.sql index 6e65bf1..28cfd21 100644 --- a/sqlite/privacy_preferences.sql +++ b/sqlite/privacy_preferences.sql @@ -1,7 +1,7 @@ -- privacy_preferences definition CREATE TABLE privacy_preferences ( - id INTEGER NOT NULL, + id INTEGER NOT NULL PRIMARY KEY, discovery BLOB NOT NULL, discovery_user_limit TEXT NOT NULL, discovery_server_limit TEXT NOT NULL, diff --git a/sqlite/security_preferences.sql b/sqlite/security_preferences.sql index 965d0f3..9ce04a5 100644 --- a/sqlite/security_preferences.sql +++ b/sqlite/security_preferences.sql @@ -1,7 +1,7 @@ -- security_preferences definition CREATE TABLE "security_preferences" ( - id INTEGER NOT NULL, + id INTEGER NOT NULL PRIMARY KEY, account_tokens TEXT NOT NULL, password_hash TEXT NOT NULL, CONSTRAINT NewTable_FK FOREIGN KEY (id) REFERENCES users(id) ON DELETE CASCADE ON UPDATE CASCADE diff --git a/sqlite/users.sql b/sqlite/users.sql index 121e75a..4dfc8c6 100644 --- a/sqlite/users.sql +++ b/sqlite/users.sql @@ -1,7 +1,7 @@ -- users definition CREATE TABLE users ( - id INTEGER NOT NULL PRIMARY KEY AUTOINCREMENT, + id INTEGER NOT NULL PRIMARY KEY, user_name TEXT NOT NULL, display_name TEXT, activated INTEGER DEFAULT 0 NOT NULL,