[MDEV-7587] ERROR 1064 (42000) when trying to restore a mysqldump in mariadb 10.0.16 - wheezy-1 Created: 2015-02-14  Updated: 2015-02-14  Resolved: 2015-02-14

Status: Closed
Project: MariaDB Server
Component/s: Admin statements
Affects Version/s: 10.0.16
Fix Version/s: N/A

Type: Bug Priority: Critical
Reporter: Ed Jackson Assignee: Unassigned
Resolution: Not a Bug Votes: 0
Labels: None
Environment:

debian wheezy 7.8



 Description   

server1:~# mysql
Welcome to the MariaDB monitor. Commands end with ; or \g.
Your MariaDB connection id is 6085
Server version: 10.0.16-MariaDB-1~wheezy-log mariadb.org binary distribution

Copyright (c) 2000, 2014, Oracle, MariaDB Corporation Ab and others.

Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.

MariaDB [(none)]> mysql -e "source /data/disk/arch/sql/server1.domain.biz-150209-0008/xnlasocitgyabcom.sql.gz" xnlas
ocitgyabc_0 ;
ERROR 1064 (42000): You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server ve
rsion for the right syntax to use near 'mysql -e "source /data/disk/arch/sql/server1.domain.biz-150209-0008/xnlasoci
tgy' at line 1
MariaDB [(none)]> mysql xnlasocitygyabc_0 < /data/disk/arch/sql/server1.domain.biz-150209-0008/xnlasocitgyabcom.sql.
gz
-> ;
ERROR 1064 (42000): You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server ve
rsion for the right syntax to use near 'mysql xnlasocitygyabc_0 < /data/disk/arch/sql/server1.domain.biz-150209-0008
/xn' at line 1
MariaDB [(none)]>



 Comments   
Comment by Elena Stepanova [ 2015-02-14 ]

You either need to run source <your file> from the MariaDB client, or run mysql -e <your file> from the command line; but not both at once.

It is also suspicious that your dump ends with .gz – if it's really a gzip archive, you'll need to unpack it first.

Generated at Thu Feb 08 07:20:44 UTC 2024 using Jira 8.20.16#820016-sha1:9d11dbea5f4be3d4cc21f03a88dd11d8c8687422.