Doctrine 1
  1. Doctrine 1
  2. DC-752

Data type "decimal" can be unsigned in MySQL 5.0

    Details

    • Type: Bug Bug
    • Status: Open
    • Priority: Minor Minor
    • Resolution: Unresolved
    • Affects Version/s: None
    • Fix Version/s: None
    • Component/s: Native SQL, Schema Files
    • Labels:
      None
    • Environment:

      Description

      I have found in official docs of MySQL v5.0:

      Decimals can be unsigned: DECIMAL[(M[,D])] [UNSIGNED] [ZEROFILL]

      Here above is my "schema.yml" file:

      schema.yml
       
      Project:
        columns:
          id:
            type: integer(4)
            unsigned: true
            primary: true
            autoincrement: true
          salary_range_from:
            type: decimal(12)
            scale: 2
            unsigned: true
      

      After i run:

      ./symfony doctrine:build --all

      my "schema.sql" is:

      schema.sql
       
      CREATE TABLE `project` (
        `id` INT AUTO_INCREMENT, 
        `salary_range_from` DECIMAL(12, 2), 
        INDEX `company_id_idx` (`company_id`), PRIMARY KEY(`id`)
      ) DEFAULT CHARACTER SET utf8 ENGINE = INNODB;
      

        Activity

        There are no comments yet on this issue.

          People

          • Assignee:
            Roman S. Borschel
            Reporter:
            Ilya Sabelnikov
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated: