Re: MySQL DATETIME support

From: Andrus Adamchik (andru..bjectstyle.org)
Date: Tue Mar 01 2005 - 20:15:39 EST

  • Next message: Andrus Adamchik: "Re: Stored Procedure Query and Transactions"

    > Can DATETIME be added as a choice for MySQL in CM without changing the
    > code. I noticed there is a mysql/types.xml file in the distribution is
    > this where such changes can be made?

    Correct, types.xml is the way to customize it for the Modeler. I want
    to add GUI support to dynamically change this file at some point, but
    now you'll have to do it manually.

    Andrus

    On Mar 1, 2005, at 10:26 AM, JR Ruggentaler wrote:

    > I some versions of MySQL (I am using 4.0.18) TIMESTAMP is
    > automatically initialized to the current time when a row is inserted.
    > I have a table with a TIMESTAMP field and whenever I insert a row and
    > specify NULL as the TIMESTAMP field the Server sets the field to the
    > current date and time. This works the same from Cayenne and from other
    > SQL tools and is documented by MySQL as the way it works for some
    > versions of MySQL so this is NOT a Cayenne bug of any sort. The
    > simplest work around is to set the field to DATETIME but DATETIME is
    > not a choice in the Cayenne Modeler. Can DATETIME be added as a choice
    > for MySQL in CM without changing the code. I noticed there is a
    > mysql/types.xml file in the distribution is this where such changes
    > can be made?
    >
    > J.R.



    This archive was generated by hypermail 2.0.0 : Tue Mar 01 2005 - 20:15:44 EST