Slava Tutushkin wrote:
>
> Thank you, Michael.
>
> But I think it's not exactly what I am looking for.
>
>> if you're looking to change the actual format stored in the column,
>> make your own TypeDecorator which specifies the underlying format
>> desired as the "impl" ( i think in this case it would be Numeric).
>> TypeDecorator example is
>> athttp://www.sqlalchemy.org/docs/05/reference/sqlalchemy/types.html#sql...
>>   .
>
> Currently sqlalchemy is putting just "iso string" to result sql for
> sqlite. I need to replace it with "julianday(iso string)" when using
> standard DateTime column type for sqlite ONLY. This is how sqlite is
> supposed to handle the dates. I guess, TypeDecorator example does not
> fits here.
> Looks like I need to replace sqlite engine's _SLDateTime somehow. But
> how to do it without hacking the sqlalchemy source code?

"julianday" being a SQLite function ?  i.e. you'd like SQLite to do the
date arithmetic from the ISO value for you ?  or you'd like your custom
type to provide the "julianday" numeric value ?

better yet, to ensure perfect clarity here, provide a plain pysqlite
script that illustrates what API/sqlite features you'd like to use.




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

Reply via email to