PDA

View Full Version : Database transfer



Dark Vaati
11-13-2007, 08:06 AM
Hello, my name's Andreu and I'm from Barcelona, so my english is a bit poor. I've just acquired a hosting service at Hostmonster and I've got a problem I hope you can solve.

I've got a blog built with Wordpress and a forum made with phpBB in my old host. I want to transfer them all to Hostmonster so I've downloaded all files in my old host to my PC. Later I will upload them all to Hostmonster. Furthermore I've gone to php myadmin to download a copy from my database in order to import it to Hostmonster. Making some changes at config.php files it would have worked. ¿correct?

Well the pronlem comes when importing my SQL file to my Hostmonster database. I've been given this message:


Error
consulta SQL:

-- phpMyAdmin SQL Dump
-- version 2.6.4-pl2
-- http://www.phpmyadmin.net
--
-- Servidor: mysql3.freehostia.com
-- Tiempo de generación: 13-11-2007 a las 13:26:56
-- Versión del servidor: 4.1.11
-- Versión de PHP: 4.4.4-8+etch1
--
-- Base de datos: `andpre84_blog`
--
CREATE DATABASE `andpre84_blog` DEFAULT CHARACTER SET latin1 COLLATE latin1_swedish_ci;



MySQL ha dicho:

#1044 - Access denied for user 'darkvaat'@'localhost' to database 'andpre84_blog'

What's wrong? What can I do? Help me please :(

shadmego
11-13-2007, 09:25 AM
If I am not mistaken, you have to change the username (in your hostmonster account) to 'andpre84_darkvaat'. In Hostmonster, both the username and the database will be appended with the account name.

So your database will be: <accountname>_blog
And your username will be: <accountname>_user

You should also not forget to attach the user to the database, but it seems you may know to do that.

~regards, and welcome to the Community!

Dark Vaati
11-13-2007, 10:22 AM
When I tried to import the database my DB was darkvaat_blog and my user was darkvaat_blogger cause my domain here is darkvaati.net so I can't change it to andpre84_darkvaat :confused:

In the other server db and user were both andpre84_blog

r2b2
11-13-2007, 01:57 PM
I'm assuming that the database export you have is a plain text SQL file? If so, you should be able to Find/Replace the old database name with the new database name in a text editor.

Dark Vaati
11-13-2007, 03:47 PM
Hum I'll try, thanks ;)