Mercurial > hgrepos > hgweb.cgi > s4
changeset 279:7d7b81cfd3a0
Remove debug comment
author | HIROSE Yuuji <yuuji@gentei.org> |
---|---|
date | Tue, 02 Aug 2016 14:18:25 +0859 |
parents | 2f1607d8b56b |
children | 2d2d32a9bb80 |
files | s4-init.sh |
diffstat | 1 files changed, 3 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/s4-init.sh Tue Aug 02 13:25:47 2016 +0859 +++ b/s4-init.sh Tue Aug 02 14:18:25 2016 +0859 @@ -71,9 +71,10 @@ create table par '(sessid text, var text, type text, val text, primary key(sessid, var, val) foreign key(sessid) references session(id) on update cascade on delete cascade);' create table session '(id text primary key, expire text);' create table cookie '(sessid text, var text, type text, val text, primary key(sessid, var) foreign key(sessid) references session(id) on update cascade on delete cascade);' + +# For compatibility tblacc=`query "select name from sqlite_master where name='tblaccesses';"` acc=`query "select name from sqlite_master where name='acclog';"` -echo tblacc="[$tblacc]" acc="[$acc]" create table tblaccesses "(user, tbl, tblrowid, time, \ unique(user, tbl, tblrowid, time), \ foreign key(user) references user(name))" @@ -82,6 +83,7 @@ query "INSERT INTO tblaccesses SELECT * FROM acclog; DROP TABLE acclog;" fi +# Ver.2 of acclog create view acclog "AS SELECT user, tbl, tblrowid, max(time) time FROM tblaccesses GROUP by user, tbl, tblrowid;"