On Sep 20, 2013, at 10:35 AM, Philip Scott <safetyfirstp...@gmail.com> wrote:

> 
> Without actually querying the DB or enumerating the types and their 
> conversions myself which seems a bit naff;  psycopg2.extensions.adapt almost 
> does it but not quite (e.g. you get "'2013-09-10'::date" when CAST() gives 
> you "2013-09-10"). Any ideas? It's not vital, I don't do much up dating of 
> these guys really so I have it doing a supplemental SQL query like the one 
> above for every update/insert :)

date to string without SQL access....how about strftime() ?


http://docs.python.org/2/library/datetime.html#strftime-strptime-behavior


Attachment: signature.asc
Description: Message signed with OpenPGP using GPGMail

Reply via email to