Uploaded image for project: 'Doctrine 1'
  1. Doctrine 1
  2. DC-412

Error defining "unique" constraint in a translated (i18n) column

    Details

    • Type: Bug
    • Status: Open
    • Priority: Major
    • Resolution: Unresolved
    • Affects Version/s: None
    • Fix Version/s: None
    • Component/s: I18n
    • Labels:
      None

      Description

      Let's suppose we have a class "Element" with columns "name" and "description".

      We want to set an "unique" constraint in column "name", and set the I18n behavior to columns name and description.

      In the generated translation table "element_translation", doctrine sets an unique constraint in the column "name". This is an error, as various languages could translate that string in the same way. I think that the "unique" constraint should be set to the combination of columns "name" and "lang", so the restriction applies for a given language.

        Activity

        There are no comments yet on this issue.

          People

          • Assignee:
            jwage Jonathan H. Wage
            Reporter:
            davefx David Marín Carreño
          • Votes:
            1 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

            • Created:
              Updated: