MySQL Type = MyISAM错误 [英] MySQL Type=MyISAM Error

查看:47
本文介绍了MySQL Type = MyISAM错误的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

本月初,我正在论坛网站上工作,遇到了一个小问题.不幸的是,除了我的数据库外,一切都进展顺利.我正在使用此脚本在其中创建名为users的表...

I am working on my forums website earlier this month and came across a little problem. Unfortunately, everything has gone smoothly except for my database. I was making a table in it called users with this script...

CREATE TABLE `users` (
`id` int(4) NOT NULL auto_increment,
`username` varchar(65) NOT NULL default '',
`password` varchar(65) NOT NULL default '',
PRIMARY KEY (`id`)
) TYPE=MyISAM AUTO_INCREMENT=2 ;

但是,当我尝试运行代码时,出现此错误...

When I tried to run the code however, I get this error...

#1064-您的SQL语法有误;检查与您的MySQL服务器版本相对应的手册以获取正确的语法以 在第6行的"TYPE = MyISAM AUTO_INCREMENT = 2"附近使用

#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 'TYPE=MyISAM AUTO_INCREMENT=2' at line 6

我以前用Engine运行它已经处理了一次,但是这次我遇到了两个不同的错误.

I have dealt with this once before by running it with Engine, but I got two different errors when I did that this time.

我对此进行了一些研究,并认为我的MySQL代码可能已过时,但是当我从我的一台员工计算机上的同一版本的MySQL上运行该代码时,它运行良好.之后,我尝试从计算机上在旧版本的MySQL上再次运行它,但仍然出现错误.

I did some research on it and thought my MySQL code may be outdated, but when I ran the code on the same version of MySQL from my one of my employees computers, it worked fine. After that, I tried running it on an older version of MySQL from my computer again, but still got an error.

我的假设是这可能是一个简单的错误,也可能是计算机/服务器错误.我会尝试在另一台计算机上建立我的网站,说我拥有一家计算机商店,但是由于它是localhost,所以我不想从头开始.而且,我对闪存驱动器不知所措,而且由于我们一直在斯堪的那维亚北部的天气,我无法尽快将其运送出去.

My assumption is it may be a simple mistake, or a computer/server error. I would try to just do my website on a different computer, speaking that I own a computer shop, but I don't want to have to start all over since it is localhost. Also, I am at a loss for flash drives and with the weather we have been getting out here in north Scandinavia, there is no way I will be able to get it shipped any time soon.

因此,作为最后的选择,我决定问你们.感谢您的帮助.

So, as a last resort I decided to ask you guys. Help is appreciated.

推荐答案

您必须更改此

  TYPE=MyISAM

 ENGINE=MyISAM

TYPE在MySQL 4.0中已弃用,在MySQL 5.5中已删除.

TYPE was deprecated in MySQL 4.0 and removed in MySQL 5.5.

文档 http://dev.mysql.com/doc /refman/5.6/en/create-table.html

这篇关于MySQL Type = MyISAM错误的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆