Doctrine 1
  1. Doctrine 1
  2. DC-924

type mismatch for keyfield in column aggregation

    Details

    • Type: Bug Bug
    • Status: Open
    • Priority: Major Major
    • Resolution: Unresolved
    • Affects Version/s: 1.2.3
    • Fix Version/s: 1.2.3
    • Component/s: Inheritance
    • Labels:
      None
    • Environment:
      PostgreSQL

      Description

      This is the doc exemple on column aggregation inheritance :

      Entity:
      columns:
      username: string(20)
      password: string(16)
      created_at: timestamp
      updated_at: timestamp

      User:
      inheritance:
      extends: Entity
      type: column_aggregation
      keyField: type
      keyValue: 1

      Group:
      inheritance:
      extends: Entity
      type: column_aggregation
      keyField: type
      keyValue: 2

      But the keyField (type) is created as VARCHAR(255) so PostgreSQL return an error on applying inheritance condition :

      SQLSTATE[42883]: Undefined function: 7 ERROR: operator does not exist: character varying = integer
      LINE 1: ...D s.application = 'frontend' AND s.lft = 1) AND (s.type = 2)
      ^
      HINT: No operator matches the given name and argument type(s). You might need to add explicit type casts.

      I found this with symfony sfFilebasePlugin on sfFilebase:create-root task.

        Activity

        There are no comments yet on this issue.

          People

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

            Dates

            • Created:
              Updated: