Skip to content

Commit 08c5225

Browse files
author
Alexander Smishlajev
committed
use backend datatype for journal timestamps.
this fixes DateTime parsing errors raised by sqlite if mx.DateTime is installed
1 parent 56941c6 commit 08c5225

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

roundup/backends/rdbms_common.py

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# $Id: rdbms_common.py,v 1.142.2.5 2005-02-14 02:55:31 richard Exp $
1+
# $Id: rdbms_common.py,v 1.142.2.6 2005-03-02 14:09:30 a1s Exp $
22
''' Relational database (SQL) backend common code.
33
44
Basics:
@@ -526,8 +526,9 @@ def create_journal_table(self, spec):
526526
cols = ','.join(['%s varchar'%x
527527
for x in 'nodeid date tag action params'.split()])
528528
sql = '''create table %s__journal (
529-
nodeid integer, date timestamp, tag varchar(255),
530-
action varchar(255), params text)'''%spec.classname
529+
nodeid integer, date %s, tag varchar(255),
530+
action varchar(255), params text)''' % (spec.classname,
531+
self.hyperdb_to_sql_datatypes[hyperdb.Date])
531532
self.sql(sql)
532533
self.create_journal_table_indexes(spec)
533534

0 commit comments

Comments
 (0)