Doctrine DBAL
  1. Doctrine DBAL
  2. DBAL-472

Oracle schema modification - incorrect SQL to change the nullable status of column

    Details

    • Type: Bug Bug
    • Status: Resolved
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 2.3.2
    • Fix Version/s: 2.5
    • Component/s: Schema Managers
    • Security Level: All
    • Labels:
      None
    • Environment:
      Centos 6 PHP 5.3.3 Oracle 11g

      Description

      When updating the nullable status of a column the sql generated is

      ALTER TABLE MET MODIFY (METAR VARCHAR2(2000) DEFAULT NULL)

      This will set the default column value to null but does not modify the nullable status of the column. The correct sql would be

      ALTER TABLE MET MODIFY (METAR VARCHAR2(2000) NULL)

      The field definition changed from

      metar:
      type: string
      length: 2000
      nullable: false
      column: METAR

      to

      metar:
      type: string
      length: 2000
      nullable: true
      column: METAR

        Activity

        Andy Park created issue -
        Hide
        Benjamin Eberlei added a comment -

        Works for me strangely.

        Show
        Benjamin Eberlei added a comment - Works for me strangely.
        Steve Müller made changes -
        Field Original Value New Value
        Assignee Benjamin Eberlei [ beberlei ] Steve Müller [ deeky666 ]
        Steve Müller made changes -
        Status Open [ 1 ] In Progress [ 3 ]
        Hide
        Steve Müller added a comment -
        Show
        Steve Müller added a comment - Patch supplied in PR: https://github.com/doctrine/dbal/pull/467
        Hide
        Doctrine Bot added a comment -

        A related Github Pull-Request [GH-467] was closed:
        https://github.com/doctrine/dbal/pull/467

        Show
        Doctrine Bot added a comment - A related Github Pull-Request [GH-467] was closed: https://github.com/doctrine/dbal/pull/467
        Benjamin Eberlei made changes -
        Status In Progress [ 3 ] Resolved [ 5 ]
        Fix Version/s 2.5 [ 10523 ]
        Resolution Fixed [ 1 ]

        This list may be incomplete, as errors occurred whilst retrieving source from linked applications:

        • Request to http://www.doctrine-project.org/fisheye/ failed: Error in remote call to 'FishEye 0 (http://www.doctrine-project.org/fisheye/)' (http://www.doctrine-project.org/fisheye) [AbstractRestCommand{path='/rest-service-fe/search-v1/crossRepositoryQuery', params={query=DBAL-472, expand=changesets[0:20].revisions[0:29],reviews}, methodType=GET}] : Received status code 503 (Service Temporarily Unavailable)

          People

          • Assignee:
            Steve Müller
            Reporter:
            Andy Park
          • Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: