Uploaded image for project: 'Doctrine 2 - ORM'
  1. Doctrine 2 - ORM
  2. DDC-576

New entities must have primary key values right after flushing with IDENTITY strategy

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Critical
    • Resolution: Fixed
    • Affects Version/s: 2.0-BETA1
    • Fix Version/s: 2.0-BETA2
    • Component/s: ORM
    • Security Level: All
    • Labels:
      None
    • Environment:
      PostgreSQL 8.4.3, Ubuntu 10.04

      Description

      After insertion of some new entity the primary key must be set. Example code is attached above.

        Activity

        drevolution Václav Novotný created issue -
        drevolution Václav Novotný made changes -
        Field Original Value New Value
        Summary New entities must have primary key values right after flushing New entities must have primary key values right after flushing with IDENTITY strategy
        romanb Roman S. Borschel made changes -
        Assignee Roman S. Borschel [ romanb ] Benjamin Eberlei [ beberlei ]
        Hide
        romanb Roman S. Borschel added a comment - - edited

        I think I reproduced this already. Seems to be related to PostgreSQL + IDENTITY only. The SequenceIdentityGenerator must be used but apparently it is not used.

        Thanks for the report. Will keep you updated.

        ps. The standalone reproduce scripts are good. Thanks for that! If you are interested it would be even better if the test code would be provided as a unit test or with some additional comments and/or assertions about what the desired behavior is or where the supposedly wrong behavior is (even if it is very obvious, like in this issue).

        Show
        romanb Roman S. Borschel added a comment - - edited I think I reproduced this already. Seems to be related to PostgreSQL + IDENTITY only. The SequenceIdentityGenerator must be used but apparently it is not used. Thanks for the report. Will keep you updated. ps. The standalone reproduce scripts are good. Thanks for that! If you are interested it would be even better if the test code would be provided as a unit test or with some additional comments and/or assertions about what the desired behavior is or where the supposedly wrong behavior is (even if it is very obvious, like in this issue).
        romanb Roman S. Borschel made changes -
        Assignee Benjamin Eberlei [ beberlei ] Roman S. Borschel [ romanb ]
        romanb Roman S. Borschel made changes -
        Status Open [ 1 ] In Progress [ 3 ]
        romanb Roman S. Borschel made changes -
        Fix Version/s 2.0-BETA2 [ 10050 ]
        romanb Roman S. Borschel made changes -
        Comment [ OK. I think I reproduced this already. Seems to be related to PostgreSQL + IDENTITY only. The SequenceIdentityGenerator must be used but apparently it is not used.

        Thanks for the report. Will keep you updated. ]
        romanb Roman S. Borschel made changes -
        Status In Progress [ 3 ] Closed [ 6 ]
        Resolution Fixed [ 1 ]
        beberlei Benjamin Eberlei made changes -
        Workflow jira [ 11330 ] jira-feedback [ 15624 ]
        beberlei Benjamin Eberlei made changes -
        Workflow jira-feedback [ 15624 ] jira-feedback2 [ 17488 ]
        beberlei Benjamin Eberlei made changes -
        Workflow jira-feedback2 [ 17488 ] jira-feedback3 [ 19745 ]

        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={expand=changesets[0:20].revisions[0:29],reviews, query=DDC-576}, methodType=GET}] : Received status code 503 (Service Temporarily Unavailable)

          People

          • Assignee:
            romanb Roman S. Borschel
            Reporter:
            drevolution Václav Novotný
          • Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: