Doctrine 2 - ORM
  1. Doctrine 2 - ORM
  2. DDC-1231

In ObjectHydrator->_getEntity(...) looking for the discriminator should be in uppercase

    Details

    • Type: Bug Bug
    • Status: Resolved
    • Priority: Blocker Blocker
    • Resolution: Fixed
    • Affects Version/s: 2.1
    • Fix Version/s: 2.1
    • Component/s: ORM
    • Security Level: All
    • Labels:
      None

      Description

      On line 204:
      $discrColumn = $this->_rsm->metaMappings[$this->_rsm->discriminatorColumns[$dqlAlias]];

      $this->_rsm->discriminatorColumns[$dqlAlias] is in lowercase, whereas $this->_rsm->metaMappings[$this->_rsm->discriminatorColumns[$dqlAlias]] is in uppercase.

      $discrColumn cannot be assigned.

      A simple fix could be:
      $discrColumn = $this->_rsm->metaMappings[strtoupper($this->_rsm->discriminatorColumns[$dqlAlias])];

        Activity

        Hide
        Benjamin Eberlei added a comment -

        What version of the code are you using? I fixed this problem yesterday on git master.

        Show
        Benjamin Eberlei added a comment - What version of the code are you using? I fixed this problem yesterday on git master.
        Hide
        Alexandre Mathieu added a comment -

        2.1.0RC1 downloaded this morning from the website.

        Show
        Alexandre Mathieu added a comment - 2.1.0RC1 downloaded this morning from the website.
        Hide
        Benjamin Eberlei added a comment -

        ah yes, please update to Git Master then or wait for the RC2 release happening this week.

        Show
        Benjamin Eberlei added a comment - ah yes, please update to Git Master then or wait for the RC2 release happening this week.
        Hide
        Benjamin Eberlei added a comment -

        This was fixed on master

        Show
        Benjamin Eberlei added a comment - This was fixed on master

          People

          • Assignee:
            Benjamin Eberlei
            Reporter:
            Alexandre Mathieu
          • Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: