cancel
Showing results for 
Search instead for 
Did you mean: 

data migration tool: Error - Syntax error or access violation: 1142 CREATE command denied to user

SOLVED

data migration tool: Error - Syntax error or access violation: 1142 CREATE command denied to user

I am migrating from Magento 1.9.3 to 2.0.7 using the data migration tool and I get the following error: 

 Syntax error or access violation: 1142 CREATE command denied to user sourceUser

@'localhost' for table 'mg_m2_cl_
catalog_compare_item', query was: CREATE TABLE IF NOT EXISTS `mg_m2_cl_catalog_compare_item` (
`catalog_compare_item_id` int NOT NULL COMMENT 'Catalog_compare_item_id' ,
`operation` text NULL COMMENT 'Operation' ,
`processed` bool NOT NULL default '0' COMMENT 'Processed' ,
PRIMARY KEY (`catalog_compare_item_id`)
) COMMENT='mg_m2_cl_catalog_compare_item' ENGINE=INNODB charset=utf8 COLLATE=utf8_general_ci

 

My database user configuration is as suggested in the config.xml

<!--
Set direct_document_copy = 1 for better performance.
NOTE: 'source' and 'destination' databases MUST be placed on the same MySQL instance
and 'destination' user MUST be granted with 'SELECT' permissions on 'source' database
-->
My source and destination databases are databases are in the same instance, same user exists in both source and destination with select permission in the source database and full permissions on destination database.

Tried using different users for source and destination database. The Error is for the source database. It looks like the migration tool is creating tables in the source database which is not expected. Why is the tool creating tables in the source db? Do I have to grant permissions for CREATE in the source database. My biggest concern is would it create conflicts in the source db?

 

1 ACCEPTED SOLUTION

Accepted Solutions

Re: data migration tool: Error - Syntax error or access violation: 1142 CREATE command denied to us

It's creating temporary tables which are later used for migration process. You should grant "create" and "drop" privileges (it will later drop that table). You should not be concered, especially because I guess you're having backup of that database, and it's not on live server (I hope).

If this response was helpful to you, consider giving kudos to this post.
If this response solved your problem, click accept as solution to help others solve this issue

View solution in original post

1 REPLY 1

Re: data migration tool: Error - Syntax error or access violation: 1142 CREATE command denied to us

It's creating temporary tables which are later used for migration process. You should grant "create" and "drop" privileges (it will later drop that table). You should not be concered, especially because I guess you're having backup of that database, and it's not on live server (I hope).

If this response was helpful to you, consider giving kudos to this post.
If this response solved your problem, click accept as solution to help others solve this issue