Erreur SQL au Backup (Créer un compte)

  • Statut : non résolu
15 sujets de 1 à 15 (sur un total de 17)
  • Auteur
    Messages
  • #447958
    Kaze
    Membre
    Initié WordPress
    16 contributions

    Bonjour,

    J’ai un petit soucis de SQL:
    je transfere mon wordpress de free vers ovh, mais au moment ou je fais le backup via phpmyadmin chez ovh, avec le fichier telechargé avec le backup plugin, il me done l’erreur suivante:

    Erreur

    requête SQL :

    CREATE TABLE `wp_categories` (
    `cat_ID` bigint( 20 ) NOT NULL AUTO_INCREMENT ,
    `cat_name` varchar( 55 ) COLLATE latin1_general_ci NOT NULL default  »,
    `category_nicename` varchar( 200 ) COLLATE latin1_general_ci NOT NULL default  »,
    `category_description` longtext COLLATE latin1_general_ci NOT NULL ,
    `category_parent` bigint( 20 ) NOT NULL default ‘0’,
    `category_count` bigint( 20 ) NOT NULL default ‘0’,
    PRIMARY KEY ( `cat_ID` ) ,
    KEY `category_nicename` ( `category_nicename` )
    )ENGINE = MYISAM AUTO_INCREMENT = 4DEFAULT CHARSET = latin1 COLLATE = latin1_general_ci AUTO_INCREMENT =4

    MySQL a répondu:
    #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 ‘COLLATE latin1_general_ci NOT NULL default  »,
    `category_nic

    et donc la table wp_categories n’est pas créée…

    M’y connaissant pas vraiment en SQL, je fais appel à vous..

    Une idée, un conseil? 🙂

    Merci bien

    #575757
    Qwindoo
    Modérateur
    Maître WordPress
    2862 contributions

    Salut 🙂

    Il manque un espace entre 4 et DEFAULT_CHARSET 😉

    #575758
    Charlie-Show
    Participant
    Initié WordPress
    16 contributions

    HELP ME j’ai le même problème.

    #575759
    AmO
    Participant
    Maître WordPress
    4449 contributions
    CREATE TABLE `wp_categories` (
    `cat_ID` bigint(20) NOT NULL auto_increment,
    `cat_name` varchar(55) NOT NULL default  »,
    `category_nicename` varchar(200) NOT NULL default  »,
    `category_description` longtext NOT NULL,
    `category_parent` bigint(20) NOT NULL default ‘0’,
    `category_count` bigint(20) NOT NULL default ‘0’,
    PRIMARY KEY (`cat_ID`),
    KEY `category_nicename` (`category_nicename`)
    ) TYPE=MyISAM AUTO_INCREMENT=XX ;

    Dans mon code, il faut modifier la valeur ‘XX’ de AUTO_INCREMENT=XX par votre nombre de catégorie + 1 (au cas ou)

    #575760
    Charlie-Show
    Participant
    Initié WordPress
    16 contributions

    :(

    Moi j’ai ca :

    CREATE TABLE  `wp_categories` (
    `cat_ID` bigint( 20 ) NOT NULL AUTO_INCREMENT ,
    `cat_name` varchar( 55 ) COLLATE latin1_general_ci NOT NULL default  »,
    `category_nicename` varchar( 200 ) COLLATE latin1_general_ci NOT NULL default  »,
    `category_description` longtext COLLATE latin1_general_ci NOT NULL ,
    `category_parent` bigint( 20 ) NOT NULL default ‘0’,
    `category_count` bigint( 20 ) NOT NULL default ‘0’,
    PRIMARY KEY ( `cat_ID` ) ,
    KEY `category_nicename` ( `category_nicename` )
    ) ENGINE = MYISAM AUTO_INCREMENT =6 AUTO_INCREMENT =6;


    MySQL a répondu:

    #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 ‘collate latin1_general_ci NOT NULL default  »,
    `category_nice

    Que faut t-il faire, merci de votre aide ?

    Charlie.

    #575761
    AmO
    Participant
    Maître WordPress
    4449 contributions
    CREATE TABLE  `wp_categories` (
    `cat_ID` bigint( 20 ) NOT NULL AUTO_INCREMENT ,
    `cat_name` varchar( 55 ) COLLATE NOT NULL default  »,
    `category_nicename` varchar( 200 ) NOT NULL default  »,
    `category_description` longtext NOT NULL ,
    `category_parent` bigint( 20 ) NOT NULL default ‘0’,
    `category_count` bigint( 20 ) NOT NULL default ‘0’,
    PRIMARY KEY ( `cat_ID` ) ,
    KEY `category_nicename` ( `category_nicename` )
    ) ENGINE = MYISAM AUTO_INCREMENT =6;

    Essai

    #575762
    Charlie-Show
    Participant
    Initié WordPress
    16 contributions

    Ca à l’air de s’arranger mais toujours rien :

    CREATE TABLE  `wp_categories` (
    `cat_ID` bigint( 20 ) NOT NULL AUTO_INCREMENT ,
    `cat_name` varchar( 55 ) COLLATE NOT NULL default  »,
    `category_nicename` varchar( 200 ) NOT NULL default  »,
    `category_description` longtext NOT NULL ,
    `category_parent` bigint( 20 ) NOT NULL default ‘0’,
    `category_count` bigint( 20 ) NOT NULL default ‘0’,
    PRIMARY KEY ( `cat_ID` ) ,
    KEY `category_nicename` ( `category_nicename` )
    ) ENGINE = MYISAM AUTO_INCREMENT =6;

    Merci beacoup.

    #575763
    Charlie-Show
    Participant
    Initié WordPress
    16 contributions

    A chaque avancement des erreurs je supprimer ce qui n’allait pas mais maintenant je suis arriver à ce stade :

    CREATE TABLE  `wp_categories` (
    `cat_ID` bigint( 20 ) NOT NULL AUTO_INCREMENT ,
    `cat_name` varchar( 55 ) ,
    `category_nicename` varchar( 200 ) ,
    `category_description` longtext NOT NULL ,
    `category_parent` bigint( 20 ) ,
    `category_count` bigint( 20 ) ,
    PRIMARY KEY ( `cat_ID` ) ,
    KEY `category_nicename` ( `category_nicename` )
    ) ENGINE = MYISAM AUTO_INCREMENT =6;


    MySQL a répondu:

    #1050 – Table ‘wp_categories’ already exists

    Alors que aucunes base de données n’ait créer ?
    Aije fait la bonne manipulation ?
    Merci.

    #575764
    Charlie-Show
    Participant
    Initié WordPress
    16 contributions

    HELP ME ! :o:(

    #575765
    AmO
    Participant
    Maître WordPress
    4449 contributions
    Arrete de réclamer de l’aide… c’est passablement moyen…

    #1050 – Table ‘wp_categories’ already exists

    La table wp_catégorie existe…

    Essai :

    DROP TABLE IF EXISTS `wp_categories`;
    CREATE TABLE `wp_categories` (
    `cat_ID` bigint( 20 ) NOT NULL AUTO_INCREMENT ,
    `cat_name` varchar( 55 ) ,
    `category_nicename` varchar( 200 ) ,
    `category_description` longtext NOT NULL ,
    `category_parent` bigint( 20 ) ,
    `category_count` bigint( 20 ) ,
    PRIMARY KEY ( `cat_ID` ) ,
    KEY `category_nicename` ( `category_nicename` )
    ) ENGINE = MYISAM AUTO_INCREMENT =6;

    #575766
    Charlie-Show
    Participant
    Initié WordPress
    16 contributions

    Merci, je prend note !

    J’ai integrer le code que tu ma fournis, mais toujours rien :

    CREATE TABLE  `wp_comments` (
    `comment_ID` bigint( 20 ) unsigned NOT NULL AUTO_INCREMENT ,
    `comment_post_ID` int( 11 ) NOT NULL default ‘0’,
    `comment_author` tinytext COLLATE latin1_general_ci NOT NULL ,
    `comment_author_email` varchar( 100 ) COLLATE latin1_general_ci NOT NULL default  »,
    `comment_author_url` varchar( 200 ) COLLATE latin1_general_ci NOT NULL default  »,
    `comment_author_IP` varchar( 100 ) COLLATE latin1_general_ci NOT NULL default  »,
    `comment_date` datetime NOT NULL default ‘0000-00-00 00:00:00’,
    `comment_date_gmt` datetime NOT NULL default ‘0000-00-00 00:00:00’,
    `comment_content` text COLLATE latin1_general_ci NOT NULL ,
    `comment_karma` int( 11 ) NOT NULL default ‘0’,
    `comment_approved` enum( ‘0’, ‘1’, ‘spam’ ) COLLATE latin1_general_ci NOT NULL default ‘1’,
    `comment_agent` varchar( 255 ) COLLATE latin1_general_ci NOT NULL default  »,
    `comment_type` varchar( 20 ) COLLATE latin1_general_ci NOT NULL default  »,
    `comment_parent` bigint( 20 ) NOT NULL default ‘0’,
    `user_id` bigint( 20 ) NOT NULL default ‘0’,
    PRIMARY KEY ( `comment_ID` ) ,
    KEY `comment_approved` ( `comment_approved` ) ,
    KEY `comment_post_ID` ( `comment_post_ID` )
    ) ENGINE = MYISAM AUTO_INCREMENT =19 AUTO_INCREMENT =19;

    voilà que maintenant c’est la table comment, je comprend plus rien …

    #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 ‘collate latin1_general_ci NOT NULL,
    `comment_author_email` va

    Merci de ton aide .

    #575767
    Charlie-Show
    Participant
    Initié WordPress
    16 contributions

    Aie si je demmande pas d’aide persone me répond … :( snif

    #575768
    AmO
    Participant
    Maître WordPress
    4449 contributions

    Concrètement il faut virer tout les charset
    « COLLATE latin1_general_ci »

    et normalement ca devrait passer

    #575769
    Charlie-Show
    Participant
    Initié WordPress
    16 contributions

    Bon ! Merci beaucoup de ton aide.
    Donc l’importation de la base de données de Free vers OVH à fonctionner mais WordPress me demmande de faire toutes les manipulations comme quand je l’installe pour la première fois et une fois tout les manipulations effectués je n’est aucuns articles, commentaires etc … dans le blog ?

    Aurai-je oublier quelque chose ?
    Merci.

    Charlie.

    #575770
    AmO
    Participant
    Maître WordPress
    4449 contributions

    Tu as configuré correctement ton fichier wp-config.php ?

15 sujets de 1 à 15 (sur un total de 17)
  • Vous devez être connecté pour répondre à ce sujet.