Given predicate of form key[=value]
can be applied to given subject, softly overriding previous predicate of form key[=old]
There is two tables:
sentences
:
id
is just autoincrementing primary keytime
is date and time when row was addedsubject
is subject identifierpredicate
is predicate applied to subject at given timeactual
is boolean indicator of predicate actuality
with indexes on
time
predicate
whereactual
istrue
subject
,actual
predicates
:
id
is just autoincrementing primary keypredicate
is explicit predicate representation
with index on predicate
select
operation implemented as generator taking predicate
and returning all corresponding subjects actual properties
name | type |
---|---|
id | integer primary key autoincrement |
time | datetime default(datetime('now')) not null |
subject | integer not null default(last_insert_rowid()) |
predicate | integer not null |
actual | integer default(1) not null |
name | types |
---|---|
id | integer primary key autoincrement |
predicate | text unique |
name | type |
---|---|
id | bigserial primary key |
time | timestamp default(now() at time zone 'utc') not null |
subject | bigint not null default currval('sentences_id_seq') |
predicate | bigint not null |
actual | boolean default(true) not null |
name | type |
---|---|
id | bigserial primary key |
predicate | text unique |