From: Mike Bayer Date: Wed, 26 Sep 2012 14:20:56 +0000 (-0400) Subject: - [feature] Added support for the localtimestamp() X-Git-Tag: rel_0_8_0b1~127 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=0c7b989ce5e50e39be03870e4ee3f809918af3b6;p=thirdparty%2Fsqlalchemy%2Fsqlalchemy.git - [feature] Added support for the localtimestamp() SQL function implemented in SQLite, courtesy Richard Mitchell. Added test --- diff --git a/CHANGES b/CHANGES index 46091f077c..a727501a76 100644 --- a/CHANGES +++ b/CHANGES @@ -905,6 +905,10 @@ are also present in 0.8. old SQLite versions that don't deliver default info as a string. [ticket:2265] + - [feature] Added support for the localtimestamp() + SQL function implemented in SQLite, courtesy + Richard Mitchell. + - postgresql - [bug] Columns in reflected primary key constraint are now returned in the order in which the constraint diff --git a/test/dialect/test_sqlite.py b/test/dialect/test_sqlite.py index 3f714b8255..07995cdc4b 100644 --- a/test/dialect/test_sqlite.py +++ b/test/dialect/test_sqlite.py @@ -590,6 +590,12 @@ class SQLTest(fixtures.TestBase, AssertsCompiledSQL): "1" ) + def test_localtime(self): + self.assert_compile( + func.localtimestamp(), + 'DATETIME(CURRENT_TIMESTAMP, "localtime")' + ) + def test_constraints_with_schemas(self): metadata = MetaData() t1 = Table('t1', metadata,