Support » Installing WordPress » Error when importing sql database to phpmyadmin

  • Hi everyone..

    I am attempting to transfer my site to my host and have taken the following steps:

    1) I have exported the mysite.sql database and saved as a text file (sql).

    2) I have changed the http://localhost/mysite occurrences with http://www.mysite.com, so that hte paths to all documents are correct

    3) I also have chanched C:\wamp\www\mysite\blog\wp-content\uploads
    with /wp-content/uploads

    However, when I go to import the sql file into phpmyadmin I get the following error:

    Error
    SQL query:


    — Database: ososantoso

    — ——————————————————–

    — Table structure for table wp_commentmeta

    CREATE TABLE wp_commentmeta (

    meta_id BIGINT( 20 ) UNSIGNED NOT NULL AUTO_INCREMENT ,
    comment_id BIGINT( 20 ) UNSIGNED NOT NULL DEFAULT ‘0’,
    meta_key VARCHAR( 255 ) DEFAULT NULL ,
    meta_value LONGTEXT,
    PRIMARY KEY ( meta_id ) ,
    KEY comment_id ( comment_id ) ,
    KEY meta_key ( meta_key )
    ) ENGINE = MYISAM DEFAULT CHARSET = utf8 AUTO_INCREMENT =1;

    MySQL said:

    #1046 – No database selected

    help me please.. what should i do?

Viewing 15 replies - 1 through 15 (of 19 total)
  • did you create a new empty database to import into?

    yes.. but actually the website is loaded like this http://ososantoso.com/
    it doesnt look like on my localhost.

    is it because i haven’t import .sql to the phpMyAdmin?

    help me please.. i’m desperate..

    one of your 2 url’s are wrong
    fix them to both be correct
    http://codex.wordpress.org/Changing_The_Site_URL

    even the sidebars is not supposed to be like that.

    Thank you for your help so far.
    Really helpfull link!!)
    I’ve changed the url and now i can see my test posts n pages

    but i think the dashboard not working well because i still have a problem with widgets (i can’t drag n drop just like on local host or open the sidebar menu) although i activated all off the plugins needed n resetting it again.

    and i can’t make new post. i can write the title but i can’t make the content. if i go to edit post, the content font colored white.

    i’m sorry if this post not the same theme with the headline. i just try to get some help.

    and i still can’t import my .sql

    1. Install wordpress as a new install
    2. do a data only export from your old database (check structure off)
    3. insert the data into the new db
    4. install your theme

    i don’t really get it
    can u please send me the link to do that? i’m new at this

    What part don’t you get?
    1. Do you know how to install wordpress? (if not, i’m sure your host will have a 1-click install of sorts or go to http://codex.wordpress.org/Installing_WordPress for instructions
    2. Data export.. You have xampp installed to run your own server. They also install phpmyadmin for you. Here is how to do it (except for the part where you check structure off) http://codex.wordpress.org/Backing_Up_Your_Database
    3. Insert the data into the db using phpmyadmin http://codex.wordpress.org/Restoring_Your_Database_From_Backup
    4. Install your theme

    is this mean i have to do it from the begining?
    my site (http://ososantoso.com/) is running, but i can’t make a post, blog page dosn’t work and can’t costomize my widgets

    1. my host have a 1 click install as u said. but it’s wordpress 3.0.4
    is it maybe the problem? i’m using http://www.jino.ru/
    2. i can’t import my .sql (i faild at no.3 as u said the last time)

    Error
    SQL query:
    
    --
    -- Database: <code>ososantoso</code>
    --
    -- --------------------------------------------------------
    --
    -- Table structure for table <code>wp_commentmeta</code>
    --
    DROP TABLE IF EXISTS  <code>wp_commentmeta</code> ;
    
    MySQL said: 
    
    #1046 - No database selected

    Why don’t you just export the post from WP and import it in the new wp install?

    i’ve done all of that step but still i can’t make any post. or change content from visual to html.

    the database still empty, it’s a new wp install. the url is right.
    what can be wrong?

    it just blank post, but if i highlight the post and the text is there. it’s white colored. and the widgets dosn’t work.

    i also ask the hosting company and they said they supported wordpress.
    it runs PHP 5.2 although they offer PHP 5.3 also.
    i turned on every setting for .htaccess
    i’m desperate.. i have no idea where to look for an answer.

    do i have to turn on all of the modules like MagickWand,RAR,GMP,SSH2
    or maybe frameworks Django?

    Do you still have access to your old site?

    yes. it’s on my wampserver. this one is brand new. i’ve done the “5min install”. but the problem is still there. even the theme is original

    Have you tried exporting the content from your local install and then importing that into your remote site?

Viewing 15 replies - 1 through 15 (of 19 total)
  • The topic ‘Error when importing sql database to phpmyadmin’ is closed to new replies.