After I've upgraded EE from 2.6.1 to 2.7.2, on most of my pages I'm now getting the following error:

Error Number: 1054

Unknown column 'L0.grid_field_id' in 'field list'

SELECT DISTINCT `L0`.`field_id` as L0_field, `L0`.`grid_field_id` as L0_grid_field_id, `L0`.`grid_col_id` as L0_grid_col_id, `L0`.`grid_row_id` as L0_grid_row_id, `L0`.`parent_id` AS L0_parent, `L0`.`child_id` as L0_id FROM (`exp_relationships` as L0) LEFT JOIN `exp_relationships` as L1 ON `L0`.`child_id` = `L1`.`parent_id` OR L1.parent_id = NULL WHERE `L0`.`grid_field_id` = 0 AND `L0`.`parent_id` IN (1389) ORDER BY `L0`.`order` asc

Filename: models/relationship_model.php

Line Number: 178

I've seen another SE post about it being something to do with the 'setup' script - but it doesn't give any more information.

Anyone seen this before? Any solutions anywhere?


Shortly after posting this - I think I found the problem. It appears the _updates_relationships_for_grid() function didn't fire in the ud_270.php upgrade process... no idea why though since the upgrade didn't fail or error at any point.

Having manually executed the SQL necessary on this function, it looks like it's working now.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.