diff options
author | Mike Bayer <mike_mp@zzzcomputing.com> | 2008-02-01 01:16:18 +0000 |
---|---|---|
committer | Mike Bayer <mike_mp@zzzcomputing.com> | 2008-02-01 01:16:18 +0000 |
commit | a0ffeb546468e14fa9d99b30571f7b8f9b32f421 (patch) | |
tree | 607a0ba4ae7ca8ff38eed0b57cd2e2a3e21c18fe /lib/sqlalchemy/sql/functions.py | |
parent | 7bf0fca85856a3662f713e3cc9e451b3c0ac344b (diff) | |
download | sqlalchemy-a0ffeb546468e14fa9d99b30571f7b8f9b32f421.tar.gz |
- some consolidation of tests in select.py, moved
other tests to more specific modules
- added "now()" as a generic function; on SQLite and
Oracle compiles as "CURRENT_TIMESTAMP"; "now()"
on all others [ticket:943]
Diffstat (limited to 'lib/sqlalchemy/sql/functions.py')
-rw-r--r-- | lib/sqlalchemy/sql/functions.py | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/lib/sqlalchemy/sql/functions.py b/lib/sqlalchemy/sql/functions.py index 869df46a7..be1d8eb61 100644 --- a/lib/sqlalchemy/sql/functions.py +++ b/lib/sqlalchemy/sql/functions.py @@ -35,6 +35,9 @@ class coalesce(GenericFunction): kwargs.setdefault('type_', _type_from_args(args)) GenericFunction.__init__(self, args=args, **kwargs) +class now(GenericFunction): + __return_type__ = sqltypes.DateTime + class concat(GenericFunction): __return_type__ = sqltypes.String def __init__(self, *args, **kwargs): |