I have an old backup sql file with `
in it. When I try to load it via psql dbname < db_backup.sql
I get an error:
ERROR: syntax error at or near "`" DROP TABLE IF EXISTS `tablename`;
Is there a way to tell psql to treat `
like '
?
I have an old backup sql file with `
in it. When I try to load it via psql dbname < db_backup.sql
I get an error:
ERROR: syntax error at or near "`" DROP TABLE IF EXISTS `tablename`;
Is there a way to tell psql to treat `
like '
?
You should create the dump using mysqldump --compatible=ansi
to avoid this and other migration incompatibilities. I suggest you make a separate MySQL database using your existing backup as it is, then do a dump with this option to make the compatible one.