If you define your column as DateTime, then SA will use the db's datetime
column.

If you want to store time in integer, i think you can just set the column to
integer, and set the column value as int(time.time())

- Didip -

On Thu, Jul 2, 2009 at 9:52 AM, Lukasz Szybalski <[email protected]>wrote:

>
> Hello,
> What is the equivalent of the following but in the integer version.
>
>
>  Column('_last_updated', DateTime(True),
>                                    default=func.current_timestamp(),
>                                    onupdate=func.current_timestamp()),
>
>  Column('_last_updated', Integer, default=int(time.time(),
> onupdate=func.???),
>
>
> I see that project like trac uses the integer timestamps extensively.
> Can it be used safely in any other project or there are some drawbacks
> for it?
>
> Thanks,
> Lucas
>
>
>
>
> --
> Using rsync. How to setup rsyncd.
> http://lucasmanual.com/mywiki/rsync
> DataHub - create a package that gets, parses, loads, visualizes data
> http://lucasmanual.com/mywiki/DataHub
>
> >
>

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"sqlalchemy" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to 
[email protected]
For more options, visit this group at 
http://groups.google.com/group/sqlalchemy?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to