[Zope] MySQL, ZMYSQLDA and date fields
Peter Bengtsson
peter@grenna.net
Sun, 4 Mar 2001 17:26:21 -0000
I had the problem with TIME fields.
Somewhere at the top of db.py in /lib/python/Products/ZMySQLDA/ is a
dictionary of fields to be converted. You'll find you fieldtype there as
well. Comment it out from the conv dictionary.
Or try to solve the problem by enclosing the DateTime stuff in a try: -
except: clause.
Peter
----- Original Message -----
From: "Salvatore Sciacco" <sas@prometeus.net>
To: <zope@zope.org>
Sent: Saturday, March 03, 2001 4:09 PM
Subject: [Zope] MySQL, ZMYSQLDA and date fields
> Hello,
>
> I've a MySQL table with some datetime fields (not null). By default MYSQL
put
> '0000-00-00 00:00:00' (a zero date) in these field. When this happen I
can't
> select these fields anymore because Zope raise an invalid date format
> exception.
>
> Do you know a workaround for this problem?
>
> Thank you.
>
> --
> Best regards,
> Salvatore Sciacco mailto:sas@prometeus.net
>
>
>
> _______________________________________________
> Zope maillist - Zope@zope.org
> http://lists.zope.org/mailman/listinfo/zope
> ** No cross posts or HTML encoding! **
> (Related lists -
> http://lists.zope.org/mailman/listinfo/zope-announce
> http://lists.zope.org/mailman/listinfo/zope-dev )