server/sources/native.py
changeset 10208 249126034c0e
parent 10206 0ecd61f4bd37
child 10209 4c64a41c0a1d
equal deleted inserted replaced
10207:5ec5d17b5e5b 10208:249126034c0e
  1385 
  1385 
  1386 CREATE TABLE entities (
  1386 CREATE TABLE entities (
  1387   eid INTEGER PRIMARY KEY NOT NULL,
  1387   eid INTEGER PRIMARY KEY NOT NULL,
  1388   type VARCHAR(64) NOT NULL,
  1388   type VARCHAR(64) NOT NULL,
  1389   asource VARCHAR(128) NOT NULL,
  1389   asource VARCHAR(128) NOT NULL,
  1390   extid VARCHAR(256)
  1390   extid VARCHAR(256) UNIQUE
  1391 );;
  1391 );;
  1392 CREATE INDEX entities_type_idx ON entities(type);;
  1392 CREATE INDEX entities_type_idx ON entities(type);;
  1393 CREATE INDEX entities_extid_idx ON entities(extid);;
       
  1394 
  1393 
  1395 CREATE TABLE transactions (
  1394 CREATE TABLE transactions (
  1396   tx_uuid CHAR(32) PRIMARY KEY NOT NULL,
  1395   tx_uuid CHAR(32) PRIMARY KEY NOT NULL,
  1397   tx_user INTEGER NOT NULL,
  1396   tx_user INTEGER NOT NULL,
  1398   tx_time %s NOT NULL
  1397   tx_time %s NOT NULL