This commit is contained in:
2020-01-24 21:08:59 +00:00
parent 61c01a5e9b
commit 0f17207d20

View File

@@ -145,7 +145,7 @@ namespace AyaNova.Util
//SEARCH TABLES
exec("CREATE TABLE asearchdictionary (id BIGSERIAL PRIMARY KEY, word varchar(255) not null)");
//LOOKAT: this index is periodically being violated during testing
//Search dictionary words must be unique
exec("CREATE UNIQUE INDEX asearchdictionary_word_idx ON asearchdictionary (word);");
exec("CREATE TABLE asearchkey (id BIGSERIAL PRIMARY KEY, wordid bigint not null REFERENCES asearchdictionary (id), objectid bigint not null, objecttype integer not null, inname bool not null)");
@@ -209,7 +209,7 @@ namespace AyaNova.Util
//Add widget table
//id, text, longtext, boolean, currency,
exec("CREATE TABLE awidget (id BIGSERIAL PRIMARY KEY, name varchar(255) not null, serial bigint not null," +
"startdate timestamp, enddate timestamp, dollaramount decimal(19,5), active bool, roles int4, count integer,"+
"startdate timestamp, enddate timestamp, dollaramount decimal(19,5), active bool, roles int4, count integer," +
"notes text, userid bigint null, customfields text, tags varchar(255) ARRAY)");
//TEST TEST TEST ONLY FOR DEVELOPMENT TESTING TO ENSURE UNIQUENESS