MyBB Community Forums

Full Version: errors when importing a database to phpmyadmin
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
i have been trying to importe the database to phpmyadmin 
then it sends this error
How was the export taken exactly? It looks like characters from MyCodes but there's no reason for them to cause this as they're just strings.

[Image: ksperOG.png]

(2023-01-17, 04:39 PM)Matt Wrote: [ -> ]How was the export taken exactly? It looks like characters from MyCodes but there's no reason for them to cause this as they're just strings.

i took it from phpmyadmin

what is the solution then?
(2015-10-30, 09:44 PM)oakstreet1 Wrote: [ -> ]I can see a few possible problems. It depends on what the target server is expecting. More recent versions of SQL have stopped using a \ to escape single quotes and instead have made a '' (repeated single quote) mean the same as an escaped single quote (\'). If that's the case, then the empty fields that have '' will look like an escaped single quote, which would screw up the syntax.

You can do one of several things.
a) re-export the data from the source database with different syntax, if you have that option
b) adjust the import settings on the target database to not use doubled single quotes as escaped single quotes
c) do a search and replace on the ''. Maybe you could replace them with NULL?

The other possible problem could be a difference in character-sets. Make sure you're using the correct encoding for importing on the new server.

I'm not as familiar with MySQL as I am with some other database engines, so I can't be really specific. I hope this helps.

- https://community.mybb.com/post-1195622.html#pid1195622

Quote:I solved similar issue when trying to import a database backup from the same host into the phpMyAdmin. Since the report mentioned first errors around some linebreaks I figured it had to be something with encoding (still all files were utf-8).

When I simply imported unpacked .sql file all was fine, so this must be some bug in the on-the-fly unpacker in phpMyAdmin (v.4.8.5 in my case).

- https://stackoverflow.com/a/54849616