Index: openacs-4/packages/acs-tcl/tcl/security-procs-postgresql.xql =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-tcl/tcl/security-procs-postgresql.xql,v diff -u -r1.5 -r1.6 --- openacs-4/packages/acs-tcl/tcl/security-procs-postgresql.xql 19 Apr 2001 14:52:47 -0000 1.5 +++ openacs-4/packages/acs-tcl/tcl/security-procs-postgresql.xql 24 Apr 2001 06:02:27 -0000 1.6 @@ -1,33 +1,55 @@ - - - postgresql - 7.1 - + postgresql7.1 - - - insert into secret_tokens(token_id, token, timestamp) - values (sec_security_token_id_seq.nextval, :random_token, now()) - - - - - select token_id, token - from secret_tokens, - (select trunc(random()*(select count(*)-15 from secret_tokens))::integer as first) r - where token_id >= r.first and r.first+15 > token_id; - - - - + + + update users set second_to_last_visit = last_visit, last_visit = now(), n_sessions = n_sessions + 1 where user_id = :user_id - - + + + + + + + + select test_sql('select 1 where 1=[DoubleApos $value]') + + + + + + + select test_sql('select 1 where 1=[DoubleApos "'$value'"]') + + + + + + + + insert into secret_tokens(token_id, token, timestamp) + values(sec_security_token_id_seq.nextval, :random_token, now()) + + + + + + + + + select token_id, token + from secret_tokens, + (select trunc(random()*(select count(*)-15 from secret_tokens))::integer as first) r + where token_id >= r.first and r.first+15 > token_id; + + + + +