Feature #4915
insert_time should be timestamptz
0%
Description
We should be providing all date logging with timestamps, so that it's easier to work in our clients respective timezones
Updated by Aurynn Shaw almost 18 years ago
- Status changed from New to In Progress
Okay. Ideas on changing the timezone based on the requesting user? Or should that even be necessary to do?
Updated by Darcy Buskermolen almost 18 years ago
Well there are a few ways to do that, a little bit of JS to read the TZ, and then forward that as part of the request ? pesudo code both client and server side:
get_tz.js:
timezone_get(){
// returns 'America/Edmonton'
return browser.timezone;
}
sever side:
begin;
set tz to 'America/Edmonton';
select * from table where insert_time > now() - '3 hours';
rollback;
Updated by Aurynn Shaw about 17 years ago
That ought to be in the environment too, so I can pick it up from Apache/the CGI directly?
Updated by bford - about 17 years ago
Hmmm, do we want to provide the TZ from the browser, or do we want to provide it from the DB?
Updated by Aurynn Shaw about 17 years ago
I was thinking we wanted to display in the timezone that the user is in.