Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

Database Restore Help Required Please


Guest

Recommended Posts

Hi all,

 

I've just moved server and have an sql Database backup file, but I can't seem to actually get it to work on my new server. I'm really dim when it comes to this as it's not something I've trained in, so can anyone help?

 

The file I have was created by old hosting company, not by me, so I can't just use the facility in OSCommerce like I did before. I've tried to use it in phpmyadmin, but I keep getting this error:

 

Error

 

SQL query:

 

--

-- Database: `blackdra_`

--

CREATE DATABASE `blackdra_` DEFAULT CHARACTER SET latin1 COLLATE latin1_swedish_ci;

 

MySQL said: Documentation

#1044 - Access denied for user 'blackdra'@'localhost' to database 'blackdra_'

 

I have no idea what that means.

 

Can anyone help?

 

Cheers,

Loups

Link to comment
Share on other sites

Hi all,

 

I've just moved server and have an sql Database backup file, but I can't seem to actually get it to work on my new server. I'm really dim when it comes to this as it's not something I've trained in, so can anyone help?

 

The file I have was created by old hosting company, not by me, so I can't just use the facility in OSCommerce like I did before. I've tried to use it in phpmyadmin, but I keep getting this error:

I have no idea what that means.

 

Can anyone help?

 

Cheers,

Loups

Perhap set yourself up as a user with admininistration rights via phpmyadmin.

Link to comment
Share on other sites

Okaaaay. How do I do that? I've looked and I can't find anything where I can add admin rights. <_<

Somewhere in phpmyadmin there should be a user with admin rights with the same name (and password) as in your configure.php files.

 

In phpmyadmin, connect to database, click privileges, and a list of users come up. If you click on action, you can edit privileges.

 

Back at the screen where you selected the database, select privileges, and there is an option to add a new user.

Link to comment
Share on other sites

Well, I've looked and better looked and I can't find privileges anywhere.

 

If I click on the database I get the following tabs:

 

Structure: SQL: Search: Query: Export: Import: Operations

 

But I can't see Privileges anywhere. Am I looking in the wrong place?

 

On the main MyPHPAdmin page, it says:

 

Create new database: Documentation

No Privileges

 

Is this relevant at all?

 

Thanks for your time!

Link to comment
Share on other sites

Well, I've looked and better looked and I can't find privileges anywhere.

 

If I click on the database I get the following tabs:

 

Structure: SQL: Search: Query: Export: Import: Operations

 

But I can't see Privileges anywhere. Am I looking in the wrong place?

 

On the main MyPHPAdmin page, it says:

Is this relevant at all?

 

Thanks for your time!

Create new database

Collation

Show MySQL runtime information

Show MySQL system variables

Show processes

Character Sets and Collations

Storage Engines

Reload MySQL

Privileges <--------------------------------------------

Databases

Export

Import

Link to comment
Share on other sites

look like the dbase name do not match the name in configure.php.The dbase name, the dbase username and the dbase password have to be correct in configure.php.If you can not figure out, the just create new one.Run clean install and after everything works, import your dbase .If any of files has been modufi, just uupload and overwrite the new one, bun not configure.php.

Link to comment
Share on other sites

Create new database

Collation

Show MySQL runtime information

Show MySQL system variables

Show processes

Character Sets and Collations

Storage Engines

Reload MySQL

Privileges <--------------------------------------------

Databases

Export

Import

 

Nope:

 

# Create new database:

No Privileges

# Show MySQL runtime information

# Show MySQL system variables

# Processes

# Character Sets and Collations

# Storage Engines

# Databases

# Export

# Import

# Log out Info

 

Is what I have!

Link to comment
Share on other sites

Nope:

 

# Create new database:

No Privileges

# Show MySQL runtime information

# Show MySQL system variables

# Processes

# Character Sets and Collations

# Storage Engines

# Databases

# Export

# Import

# Log out Info

 

Is what I have!

Perhaps you do not have a database created. Try create new database, but give it the same name as your shop database, with same user as your shop database, and give that user full privileges. Then do the restore of your shop database file (copy to backups directory and restore from admin).

Link to comment
Share on other sites

Perhaps you do not have a database created. Try create new database, but give it the same name as your shop database, with same user as your shop database, and give that user full privileges. Then do the restore of your shop database file (copy to backups directory and restore from admin).

 

No, I defiantly do have a database created. But I'll try that anyway.

Link to comment
Share on other sites

That worked well...

 

1064 - 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: `blackdra_` -' at line 10

 

-- phpMyAdmin SQL Dump -- version 2.11.0 -- http://www.phpmyadmin.net -- -- Host: localhost -- Generation Time: Oct 17, 2007 at 12:32 PM -- Server version: 4.1.22 -- PHP Version: 5.2.3 SET SQL_MODE="NO_AUTO_VALUE_ON_ZERO"; -- -- Database: `blackdra_` -

 

[TEP STOP]

 

1146 - Table 'blackdra_BlackDragon.sessions' doesn't exist

 

select count(*) as total from sessions where sesskey = '4d0249a2156098957a69c462f4a37aec'

 

[TEP STOP]

 

Think I need to take a course in this as it's just too complicated!

Link to comment
Share on other sites

That worked well...

Think I need to take a course in this as it's just too complicated!

Is this installed on the web or on your PC?

What mysql version are you using?

Link to comment
Share on other sites

Is this installed on the web or on your PC?

What mysql version are you using?

 

On the web. Version 4.1.22 according to the MyPHPAdmin home page.

Link to comment
Share on other sites

On the web. Version 4.1.22 according to the MyPHPAdmin home page.

Sorry, was looking at v5. You add users in mysql for your version. Was it a higher version previously?

 

However, the syntax error is something else. You could try creating the table 'blackdra_BlackDragon.sessions'

Link to comment
Share on other sites

Sorry, was looking at v5. You add users in mysql for your version. Was it a higher version previously?

 

However, the syntax error is something else. You could try creating the table 'blackdra_BlackDragon.sessions'

 

Ahh, I see. I didn't think to say what version it was, so my fault! Tbh, I have no idea what the previous version was as I had SO much trouble with the hosting company I was spending more time trying to sort out all the problems than doing anything else!

 

It wasn't a huge database and everything's working well at the moment, so I might just cop-out and ask customers to resubmit their details! But I will try the 'blackdra_BlackDragon.sessions' first and see what happens.

 

Cheers!

 

Edit: Just remembered, I can't use underscores so not sure how to get past that. <_<

Link to comment
Share on other sites

Ahh, I see. I didn't think to say what version it was, so my fault! Tbh, I have no idea what the previous version was as I had SO much trouble with the hosting company I was spending more time trying to sort out all the problems than doing anything else!

 

It wasn't a huge database and everything's working well at the moment, so I might just cop-out and ask customers to resubmit their details! But I will try the 'blackdra_BlackDragon.sessions' first and see what happens.

 

Cheers!

 

Edit: Just remembered, I can't use underscores so not sure how to get past that. <_<

No, I should asked what version.

 

How come no underscores? I thought that was common in table names if you want to use one database for mutiple applications.

Link to comment
Share on other sites

No, I should asked what version.

 

How come no underscores? I thought that was common in table names if you want to use one database for mutiple applications.

 

I don't know. It seems odd doesn't it?

 

OK, what I tried was to just do "BlackDragon.sessions" as the first part of "blackdra" is created automatically, so I would end up with "blackdra_BlackDragon.sessions"

 

Only, I keep getting an error that says, "The Database name can only contain numbers and/or letters" so I'm guessing the full-stop is stopping it being accepted. This is through cpanel's interface by the way, not PHPMyAdmin; I can't find anywhere to make a new database there.

 

Quick thought: is there a way to update PHPMyAdmin, or do you have to stick with the version your host provides?

Link to comment
Share on other sites

  • 2 weeks later...

I hate to bump this topic, but I really do need to get this sorted now as I've just come across a problem and I need to consult my old database in order to resolve this issue.

 

Again, is it possible to update my version of PHPmyadmin to the newest version so I can manually create a new database with the same name as the file I have? Currently I can only do it through cpanel and it's not working!

 

Many thanks in advance,

Loups

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...