dongpao5127
dongpao5127
2012-10-13 08:32

MyISAM表的BigDump错误

已采纳

I'm trying to import a a database using BigDump but it is giving me this error:

Error at the line 238: ) ENGINE=MyISAM */;
Query: `username` varchar(64),
`name` varchar(255),
`entityRef` int(11),
`Date` date,
`contactName` varchar(255),
`email` varchar(255),
`tel` varchar(128),
`Qualifies` varchar(3)
) ENGINE=MyISAM */
MySQL: 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
'`username` varchar(64), `name` varchar(255), `entityRef` int(11), `Date` d' at line 1

I am totally stumped with this one as I have used BigDump before with no problems.

How can I fix this?


Here is the block in the sql file being imported:

DROP TABLE IF EXISTS `_funnel`;
/*!50001 DROP VIEW IF EXISTS `_funnel`*/;
SET @saved_cs_client     = @@character_set_client;
SET character_set_client = utf8;
/*!50001 CREATE TABLE `_funnel` (
`username` varchar(64),
`name` varchar(255),
`entityRef` int(11),
`Date` date,
`contactName` varchar(255),
`email` varchar(255),
`tel` varchar(128),
`Qualifies` varchar(3)
) ENGINE=MyISAM */;
SET character_set_client = @saved_cs_client;

Also I have a few views in my exported SQL file. Could this be an issue?

  • 点赞
  • 写回答
  • 关注问题
  • 收藏
  • 复制链接分享
  • 邀请回答

1条回答

  • dtyrxmoj20617 dtyrxmoj20617 9年前

    here is updated sql, I put the comments after ;.

    DROP TABLE IF EXISTS `_funnel`;
    /*!50001 DROP VIEW IF EXISTS `_funnel`;*/
    SET @saved_cs_client     = @@character_set_client;
    SET character_set_client = utf8;
    /*!50001 CREATE TABLE `_funnel` (
    `username` varchar(64),
    `name` varchar(255),
    `entityRef` int(11),
    `Date` date,
    `contactName` varchar(255),
    `email` varchar(255),
    `tel` varchar(128),
    `Qualifies` varchar(3)
    ) ENGINE=MyISAM ;*/
    SET character_set_client = @saved_cs_client;
    

    But you should create the table I think. Why you are putting comments in creation statement

    点赞 评论 复制链接分享

为你推荐