MyBB Community Forums

Full Version: Any way of Skipping a table from the database?
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Pages: 1 2
Try a search/replace of this:

mybb_google_seo( active, idtype, id, url )

Into this:

mybb_google_seo( 'active', 'idtype', 'id', 'url' )
You should've reported this in the Google SEO thread, I only came across this by chance. Wink

Turns out the MyBB Backup utility is not capable of backing up the Google SEO table correctly; mainly because it does not recognize NULL, and puts it as '' (empty string) into the backup SQL instead.

With the Google SEO table this either results in a type error (because the active row requires an integer value or NULL), or in a unique restraint error (active idtype id must be unique).

This is a bug, or a limitation, of the MyBB Backup mechanism. The google seo table in itself is not wrong.

To fix, edit your SQL dump and run a search&replace

search for
INSERT INTO mybb_google_seo (active,idtype,id,url) VALUES ('',

replace with
INSERT INTO mybb_google_seo (active,idtype,id,url) VALUES (NULL,

if that still raises an error, a more aggressive approach:

search for
INSERT INTO mybb_google_seo

replace with
REPLACE INTO mybb_google_seo

If that still does not work, remove all INSERT INTO mybb_google_seo lines. The plugin will recreate the entries (but you'll lose old redirects for renamed threads).

Bug Report: http://dev.mybboard.net/issues/429
Pages: 1 2