When uploding DB to live site - #1044 - Access denied for user
Posted by: wonderland (---.cust.tele2.lv)
Date: April 12, 2016 02:05PM

Hello,

There is one thing that is bothering me. And I was hoping that it can be solved.

When I export DB from wamp's cpanel and try to import it to my live server I always get this error:
MySQL said: Documentation
#1044 - Access denied for user 'site_www'@'localhost' to database 'uspot_linkit'

I then have to open DB exported from wamp's cpanel and delete these lines:
--
-- Database: `my_site`
--
CREATE DATABASE IF NOT EXISTS `my_site` DEFAULT CHARACTER SET utf8 COLLATE utf8_general_ci;
USE `my_site`;

After I have deleted that line I can now import DB just fine. But I have to work with a lot of databases and it really adds up time when I have to always delete this line.

Is it possible for this line not to be generated?

P.S This wasn't a problem until wamp 2.4

---
1 - Windows version used -W10 64bit
2 - Version WampServer - Wamp 2.4 (not sure how to check whether 32 or 64bit, sorry)
3 - Apache Version - 2.4
4 - PHP Version - 5.4.16
5 - MySQL Version - 5.6.12
6 - What color is the WampServer icon - green

Options: ReplyQuote
Re: When uploding DB to live site - #1044 - Access denied for user
Posted by: RiggsFolly (Moderator)
Date: April 12, 2016 02:16PM

Hi

I assume by "WAMPServers CPanel" you actually mean "phpMyAdmin", is that right?

---------------------------------------------------------------------------------------------
(Windows 10 Pro 64bit) (Wampserver 3.3.4 64bit) Aestan Tray Menu 3.2.5.4
<Apache versions MULTIPE> <PHP versions MULTIPLE> <MySQL Versions MULTIPLE>
<MariaDB versions MULTIPLE> <phpMyAdmin versions MULTIPLE> <MySQL Workbench 8.0.23>

Read The Manuals Apache -- MySQL -- PHP -- phpMyAdmin
Get your Apache/MySQL/mariaDB/PHP ADDONs here from the WAMPServer alternate Repo
-X-X-X- Backup your databases regularly Here is How dont regret it later! Yes even when developing -X-X-X-

Options: ReplyQuote
Re: When uploding DB to live site - #1044 - Access denied for user
Posted by: wonderland (---.cust.tele2.lv)
Date: April 12, 2016 07:45PM

Hello,

Yes, sorry, I did mean phpMyAdmin.

Options: ReplyQuote
Re: When uploding DB to live site - #1044 - Access denied for user
Posted by: RiggsFolly (Moderator)
Date: April 12, 2016 08:15PM

Well in that case uncheck the checkbox that says

Add CREATE DATABASE / USE statement and this problem will go away.

The rest, well that may take longer to solve

---------------------------------------------------------------------------------------------
(Windows 10 Pro 64bit) (Wampserver 3.3.4 64bit) Aestan Tray Menu 3.2.5.4
<Apache versions MULTIPE> <PHP versions MULTIPLE> <MySQL Versions MULTIPLE>
<MariaDB versions MULTIPLE> <phpMyAdmin versions MULTIPLE> <MySQL Workbench 8.0.23>

Read The Manuals Apache -- MySQL -- PHP -- phpMyAdmin
Get your Apache/MySQL/mariaDB/PHP ADDONs here from the WAMPServer alternate Repo
-X-X-X- Backup your databases regularly Here is How dont regret it later! Yes even when developing -X-X-X-

Options: ReplyQuote
Re: When uploding DB to live site - #1044 - Access denied for user
Posted by: wonderland (---.cust.tele2.lv)
Date: April 12, 2016 10:06PM

I understand that this checkbox should be located in export->custom, but it isn't there.
I also checked phpMyAdmin settings and couldn't find it there either.

Closest I could find was CREATE TABLE options:
IF NOT EXISTS
AUTO_INCREMENT
But these didn't remove the before mentioned lines.


I'm sorry, but I'm not very familiar with this software outside of exporting databases.

What did you mean by "The rest, well that may take longer to solve"?



Edited 1 time(s). Last edit at 04/12/2016 10:08PM by wonderland.

Options: ReplyQuote
Re: When uploding DB to live site - #1044 - Access denied for user
Posted by: RiggsFolly (Moderator)
Date: April 13, 2016 03:24PM

Try looking at

- Export -> Custom and then under the title "Object creation options"

Is it there, sorry I am using a newer version of phpMyAdmin, but I wiuld be surprised if these titles had chnaged much since 4.0.4

---------------------------------------------------------------------------------------------
(Windows 10 Pro 64bit) (Wampserver 3.3.4 64bit) Aestan Tray Menu 3.2.5.4
<Apache versions MULTIPE> <PHP versions MULTIPLE> <MySQL Versions MULTIPLE>
<MariaDB versions MULTIPLE> <phpMyAdmin versions MULTIPLE> <MySQL Workbench 8.0.23>

Read The Manuals Apache -- MySQL -- PHP -- phpMyAdmin
Get your Apache/MySQL/mariaDB/PHP ADDONs here from the WAMPServer alternate Repo
-X-X-X- Backup your databases regularly Here is How dont regret it later! Yes even when developing -X-X-X-

Options: ReplyQuote
Re: When uploding DB to live site - #1044 - Access denied for user
Posted by: wonderland (---.cust.tele2.lv)
Date: April 15, 2016 10:31PM

I have only the following options there (guess I have to update)
Add DROP TABLE / VIEW / PROCEDURE / FUNCTION / EVENT statement
Add CREATE PROCEDURE / FUNCTION / EVENT statement
CREATE TABLE options:
-IF NOT EXISTS
-AUTO_INCREMENT

Options: ReplyQuote


Sorry, only registered users may post in this forum.