Skip to content

Column not found: 1054 Unknown column 't0.user_id' in 'where clause' #47

@webdevilopers

Description

@webdevilopers

Installed modules:

array(2) {
  ["modules"] => array(12) {
    [0] => string(18) "ZendDeveloperTools"
    [1] => string(14) "DoctrineModule"
    [2] => string(17) "DoctrineORMModule"
    [3] => string(7) "ZfcBase"
    [4] => string(7) "ZfcUser"
    [5] => string(18) "ZfcUserDoctrineORM"
    [6] => string(7) "ZfcRbac"
    [7] => string(8) "ZfcAdmin"
    [8] => string(12) "ZfcUserAdmin"
    [9] => string(11) "Application"
    [10] => string(9) "TwbBundle"
    [11] => string(11) "ZfcDatagrid"
  }

When trying to edit an user I get the following error:

Column not found: 1054 Unknown column 't0.user_id' in 'where clause'

Caused by the following query:

SELECT t1.username AS username2, t1.email AS email3, t1.display_name AS display_name4, t1.password AS password5, t1.state AS state6, t1.user_id AS user_id7 FROM user t1 WHERE t0.user_id = ?' with params ["17"]:

For some reason the query uses t1 as alias for the user table but then queries on an t0 alias for the user_id.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions