Home
Reading
Searching
Subscribe
Sponsors
Statistics
Posting
Contact
Spam
Lists
Links
About
Hosting
Filtering
Features Download
Marketing
Archives
FAQ
Blog
 
Gmane
From: Johan Dahlin <jdahlin <at> async.com.br>
Subject: [PATCH] DateTimeCol millisecond resolution support
Newsgroups: gmane.comp.python.sqlobject
Date: Tuesday 6th December 2005 12:35:12 UTC (over 11 years ago)
Some RDBMS such as Postgres and MS supports millisecond resolution.
SQLObject just ignores them, which in our application caused a trouble, 
since when getting the value back from the database it'd have the 
milliseconds removed.

This is only tested on postgres & sqlite. Mysql ignores it but parses 
the part, MS SQL supports 3 digits (3.33 ms resolution) so it should be 
able to parse the last 3 digits which datetime provides.

It's all really ISO-8601, eg:
   2005-12-06T10:27:38.6789012 (YYYY-MM-DDThh:mm:ss.s)

I didn't bother to update TimeConverter since it seems to be unused, at 
least in the revision I tried against.

The other difference is using a T as a separator instead of a space, if 
it is likely that it'll create trouble, just add a sep keyword argument 
with a single space as string value.

Johan
 
CD: 3ms