I use Panopoly and after downloading and making the updated August profile, I wasn't able to run all database updates due to this error:
panelizer module
Update #7300
Failed: PDOException: SQLSTATE[42000]: Syntax error or access violation: 1064 You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ')) AND (entity_type = '')' at line 1: DELETE FROM {panelizer_entity} WHERE (name IN ()) AND (entity_type = :db_condition_placeholder_0) ; Array ( [:db_condition_placeholder_0] => ) in panelizer_update_7300() (line 1201 of /public_html/profiles/panopoly/modules/contrib/panelizer/panelizer.install).
This is preventing the following updates of panelizer to be made:
Panelizer 7300 Remove {panelizer_entity} records with only default values.
Panelizer 7301 Add an index to {panelizer_entity} revision IDs.
Panelizer 7302 Set the storage type and ID on existing {panelizer_default} records.
Panelizer 7303 Set the storage type and ID on existing {panelizer_entity} records. This may take some time to complete.
I did not run into this issue when updating another Panopoly site however.
Comments
Comment #2
damienmckennaI believe this should have been fixed in #2788633: panelizer_update_7120: Not null violation: 7 ERROR: null value in column "pid" violates not-null, please update to the latest -dev snapshot and let me know if it fixes the problem.
Comment #3
helmo commentedThis seems to be caused by $default_names being empty... See patch.
Comment #5
helmo commentedHmm my bad, my patch was against 3.4 not the latest dev... but it turns out #2788633: panelizer_update_7120: Not null violation: 7 ERROR: null value in column "pid" violates not-null already fixed this issue.
Comment #6
damienmckennaVery happy to hear it!
Comment #7
amaisano commentedThanks - the patch in #3 worked on my non-dev version. I'm running PHP 5.4.34 and MySQL 5.5.38 btw.
Comment #8
natew commentedI was updating a site from panelizer version 7.x-3.2-beta1 to 7.x-3.4 and ran into this issue. The patch resolved this for me. Attached is a re-rolled patch without the full path to the module.
Comment #9
fredcy commentedPatch #8 here fixed the same problem for me when upgrading from 7.x-2.0 to 7.x-3.4.
Comment #10
jenlamptonThe patch in #8 fixed the problem for me as well. Thanks @natew.