Cannot Create New Gallery – “extras_post_id cannot be null” Database Error
-
Dear Imagely Support,
I am experiencing a serious issue with the NextGEN Gallery plugin (latest version) on my WordPress site.
When I try to create a new gallery or upload images, I receive the following database error in the error log:
[01-Jun-2025 14:03:10 UTC] WordPress database error Column ‘extras_post_id’ cannot be null for query INSERT INTO
wp_nh_2022ngg_gallery(author,extras_post_id,galdesc,gid,name,pageid,path,previewpic,slug,title) VALUES (‘1’, NULL, NULL, NULL, ‘uj-teszt-galeria’, ‘0’, ‘/wp-content/gallery/uj-teszt-galeria/’, ‘0’, ‘uj-teszt-galeria’, ‘uj-teszt-galeria’)This happens every time I try to create a gallery, and as a result, the gallery is not saved to the database.
What I have already checked:
- File permissions are correct (755).
- My user has administrator rights.
- The
extras_post_idcolumn in thewp_nh_2022ngg_gallerytable is set to NOT NULL. - I disabled all other plugins and switched to a default theme (Twenty Twenty-Four), but the issue persists.
It seems the plugin is failing to create the associated post entry and thus passes a NULL value into the database.
Could you please let me know how to resolve this issue?
Thank you in advance for your help.
Best regards, Tamás Horváth
The page I need help with: [log in to see the link]
The topic ‘Cannot Create New Gallery – “extras_post_id cannot be null” Database Error’ is closed to new replies.