通过mysql workbench 6.1增加表字段错误

vc2015 2014-09-04 11:06:43
环境:wndows server2008 ,mysql5.6

问题:在mysql workbench 6.1中准备给一个表增加字段时出现以下错误:

ERROR 7: Error on rename of '.\we7wq3\ims_shopping_goods.MYI' to '.\we7wq3\#sql2-43c-2d1.MYI' (Errcode: 13 - Permission denied)
SQL Statement:
ALTER TABLE `we7wq3`.`ims_shopping_goods`
ADD COLUMN `iszhekou` INT(11) NULL DEFAULT 0 AFTER `deleted`

ERROR: Error when running failback script. Details follow.

ERROR 1050: Table 'ims_shopping_goods' already exists
SQL Statement:
CREATE TABLE `ims_shopping_goods` (
`id` int(10) unsigned NOT NULL AUTO_INCREMENT,
`weid` int(10) unsigned NOT NULL,
`pcate` int(10) unsigned NOT NULL DEFAULT '0',
`ccate` int(10) unsigned NOT NULL DEFAULT '0',
`type` tinyint(1) unsigned NOT NULL DEFAULT '1' COMMENT '1为实体,2为虚拟',
`status` tinyint(1) unsigned NOT NULL DEFAULT '1',
`displayorder` int(10) unsigned NOT NULL DEFAULT '0',
`title` varchar(100) NOT NULL DEFAULT '',
`thumb` varchar(255) DEFAULT '',
`unit` varchar(5) NOT NULL DEFAULT '',
`description` varchar(1000) NOT NULL DEFAULT '',
`content` text NOT NULL,
`goodssn` varchar(50) NOT NULL DEFAULT '',
`productsn` varchar(50) NOT NULL DEFAULT '',
`marketprice` decimal(10,2) NOT NULL DEFAULT '0.00',
`productprice` decimal(10,2) NOT NULL DEFAULT '0.00',
`costprice` decimal(10,2) NOT NULL DEFAULT '0.00',
`total` int(10) NOT NULL DEFAULT '0',
`totalcnf` int(11) DEFAULT '0' COMMENT '0 拍下减库存 1 付款减库存 2 永久不减',
`sales` int(10) unsigned NOT NULL DEFAULT '0',
`spec` varchar(5000) NOT NULL,
`createtime` int(10) unsigned NOT NULL,
`weight` decimal(10,2) NOT NULL DEFAULT '0.00',
`credit` int(11) DEFAULT '0',
`maxbuy` int(11) DEFAULT '0',
`hasoption` int(11) DEFAULT '0',
`dispatch` int(11) DEFAULT '0',
`thumb_url` text,
`isnew` int(11) DEFAULT '0',
`ishot` int(11) DEFAULT '0',
`isdiscount` int(11) DEFAULT '0',
`isrecommand` int(11) DEFAULT '0',
`istime` int(11) DEFAULT '0',
`timestart` int(11) DEFAULT '0',
`timeend` int(11) DEFAULT '0',
`viewcount` int(11) DEFAULT '0',
`deleted` tinyint(3) unsigned NOT NULL DEFAULT '0',
PRIMARY KEY (`id`)
) ENGINE=MyISAM AUTO_INCREMENT=6 DEFAULT CHARSET=utf8
...全文
288 3 打赏 收藏 转发到动态 举报
AI 作业
写回复
用AI写文章
3 条回复
切换为时间正序
请发表友善的回复…
发表回复
ACMAIN_CHM 2014-09-04
  • 打赏
  • 举报
回复
\we7wq3\ 这个目录权限的问题。
vc2015 2014-09-04
  • 打赏
  • 举报
回复
当前用户是root。刚才检查了下数据表文件所在目录权限,发现没有“authenticated users”,加上并赋之修改权限后正常。不知是不是这个原因。 谢谢!
iihero 2014-09-04
  • 打赏
  • 举报
回复
ERROR 7: Error on rename of '.\we7wq3\ims_shopping_goods.MYI' to '.\we7wq3\#sql2-43c-2d1.MYI' (Errcode: 13 - Permission denied) 似乎是权限问题. 你用的当前是什么用户?最好都是administrator用户 .

56,914

社区成员

发帖
与我相关
我的任务
社区描述
MySQL相关内容讨论专区
社区管理员
  • MySQL
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧