Doctrine 1
  1. Doctrine 1
  2. DC-949

(patch)allow Native floats and double precision field types for MySQL, Oracle, Pgsql

    Details

    • Type: Improvement Improvement
    • Status: Open
    • Priority: Major Major
    • Resolution: Unresolved
    • Affects Version/s: 1.2.3
    • Fix Version/s: None
    • Component/s: Attributes
    • Labels:
      None
    • Environment:
      Os Independent, MySQL, Oracle, Postgresql

      Description

      This creates a new attribute constant Doctrine_Core::ATTR_USE_NATIVE_FLOAT and Doctrine_Core::ATTR_USE_NATIVE_DOUBLE. This will allow the setting of attributes of use_native_float = true and use_native_double = true. With these set to true in MySQL of the generated sql will no longer Make FLOAT(18,2) and will make it just FLOAT that is a true floating point the same thing with DOUBLE except it is now a true double precision floating point.

      Proper adjustments are also made to MySQL, Oracle and Postgresql to use native floating point declarations to define both single and double precision floating point data types.

      I have attached a patch to fix the floating point field types.

        Activity

        Hide
        Max Blackmer added a comment -

        Quote from MySQL Manual "For maximum portability, code requiring storage of approximate numeric data values should use FLOAT or DOUBLE PRECISION with no specification of precision or number of digits" http://dev.mysql.com/doc/refman/5.0/en/numeric-types.html

        Show
        Max Blackmer added a comment - Quote from MySQL Manual "For maximum portability, code requiring storage of approximate numeric data values should use FLOAT or DOUBLE PRECISION with no specification of precision or number of digits" http://dev.mysql.com/doc/refman/5.0/en/numeric-types.html

          People

          • Assignee:
            Jonathan H. Wage
            Reporter:
            Max Blackmer
          • Votes:
            1 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

            • Created:
              Updated: