I'm trying to restore database from backup. I've create new DB:
CREATE DATABASE `my_db` CHARACTER SET utf8
after that I launch big sql, afrter some time there written
ERROR 1064 (42000): 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 ''oy7:
commandwy24:BroadcastCommandContentsy15:changeStructure:7y7:1080582i15ay7:1' at
line 1
Does anyone know what's up here? I've tried on two backups, and I don't think both are invalid.
Thank you in advance!
Related
I try to install fleetspeak. Use Ubuntu 18.04.
First of all I run this
CREATE USER 'fleetspeak-user' IDENTIFIED BY 'fleetspeak-password';
Then I want to create database with this
CREATE DATABASE 'fleetspeak';
But has an error:
ERROR 1064 (42000): 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 ''fleetspeak'' at line 1
Why I can get this?
Try the create database script without single quotes in dbname
CREATE DATABASE fleetspeak;
I am trying to get my database example_dog_names into a sql file. The command I have tried to do this is:
example_dog_names > C:/Users/man/Desktop/dbfile.sql;
The error that I am getting says:
ERROR 1064 (42000): 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
'example_dog_names < C:/Users/man/Desktop/dbfile.sql' at line 1
What am I missing? I am connected to MySQL, and I executed the command:
USE example_dog_names;
Any help is appreciated!
I took a dump of my RDS MySQL database(5.7) with utf8 as character set and collation. Intent is to migrate the database to Aurora 5.6. During the import, I see an error where it complains about the query being incorrect. Now this is the dump file that mysql generated so my guess is that its having problem inserting the data in question. I checked for that data string in the dump and it does exist but I see nothing wrong in it. Here's the error I get during import. Any pointers ?
ERROR 1064 (42000): 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 ''2352eb05-7596-3' at line 1
In console I am trying to drop database using command
drop database database_name;
But it's throwing the below error.
ERROR 1064 (42000): 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 'database check' at line 1
I also tried to use another command:
mysqladmin -u root -p drop check;
It is throwing an error below
ERROR 1064 (42000): 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 'mysqladmin -u root -p drop check' at line 1
How to fix it?
CHECK is a reserved word in MySQL, you should use back-tick character to escape it:
DROP DATABASE `check`;
In future, try to avoid using reserved words as names of tables/databases to prevent such things from happening.
I have written the SQL file with on excecuting it is throwing the error as
mysql> #"C:\Documents and Settings\Hemant\Desktop\create_tables.sql";
ERROR 1064 (42000): 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 '#"C:\
Documents and Settings\Hemant\Desktop\create_tables.sql"' at line 1
on line 1 code is
CREATE DATABASE IF NOT EXISTS test;
DEFAULT CHARACTER SET latin1 COLLATE latin1_swedish_ci;
USE test;
please let me know is i am missing something
Correct me if I'm wrong, but isn't there a table test by default when you setup PHPMyAdmin?
You have an extra semi column after test.
Try removing it and see if that fixes the issue.