该问题已被锁定!
3
关注
3139
浏览

升级1.0时候执行?/upgrade/ 报错。无法升级

AI智能回复搜索中,请稍后...

查看全部 4 个回答

AWSupport 初级会员 用户来自于: 广东省深圳市
2012-07-27 18:07
首先在 phpmyadmin 里面手工执行 CREATE TABLE `aws_user_action_history_data` ( `history_id` int(11) unsigned NOT NULL, `associate_content` text, `associate_attached` text, PRIMARY KEY (`history_id`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8; INSERT INTO `aws_user_action_history_data` ( `history_id` , `associate_content` , `associate_attached` ) SELECT `history_id` , `associate_content` , `associate_attached` FROM `aws_user_action_history`; ALTER TABLE `aws_user_action_history` DROP `associate_content`; ALTER TABLE `aws_user_action_history` DROP `associate_attached`; ALTER TABLE `aws_user_action_history` ADD `associate_attached` INT( 11 ) NULL DEFAULT NULL; ALTER TABLE `aws_user_action_history` DROP INDEX `associate_type`; ALTER TABLE `aws_user_action_history` ADD KEY `associate` (`associate_type`,`associate_action`); ALTER TABLE `aws_user_action_history` ADD KEY ( `add_time` ); ALTER TABLE `aws_user_action_history` ADD KEY ( `uid` ); ALTER TABLE `aws_user_action_history` ADD KEY ( `associate_attached` ); ALTER TABLE `aws_user_action_history` ADD KEY `associate_with_id` ( `associate_id`, `associate_type`, `associate_action` ); CREATE TABLE `aws_notification_data` ( `notification_id` int(11) unsigned NOT NULL, `data` text, PRIMARY KEY (`notification_id`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8; INSERT INTO `aws_notification_data` ( `notification_id` , `data` ) SELECT `notification_id` , `data` FROM `aws_notification`; ALTER TABLE `aws_notification` DROP `data`; ALTER TABLE `aws_notification` ADD KEY `recipient_read_flag` (`recipient_uid`,`read_flag`); ALTER TABLE `aws_notification` ADD KEY `model` (`model_type`,`source_id`); ALTER TABLE `aws_user_action_history` CHANGE `associate_type` `associate_type` TINYINT( 1 ) NULL DEFAULT NULL COMMENT '关联类型: 1 问题 2 回答 3 评论 4 话题'; ALTER TABLE `aws_user_action_history` CHANGE `associate_action` `associate_action` SMALLINT( 3 ) NULL DEFAULT NULL COMMENT '操作类型'; ALTER TABLE `aws_users` ADD KEY ( `reputation` ); ALTER TABLE `aws_users` ADD KEY ( `reputation_update_time` ); ALTER TABLE `aws_users` ADD KEY ( `group_id` ); ALTER TABLE `aws_users` ADD KEY ( `agree_count` ); ALTER TABLE `aws_users` ADD KEY ( `thanks_count` ); ALTER TABLE `aws_users` ADD KEY ( `forbidden` ); ALTER TABLE `aws_users` ADD KEY ( `valid_email` ); ALTER TABLE `aws_reputation_topic` ADD KEY ( `topic_count` ); ALTER TABLE `aws_answer` ADD KEY ( `agree_count` ); ALTER TABLE `aws_answer` ADD KEY ( `against_count` ); ALTER TABLE `aws_answer` ADD KEY ( `add_time` ); ALTER TABLE `aws_question` ADD KEY ( `update_time` ); ALTER TABLE `aws_question` ADD KEY ( `add_time` ); ALTER TABLE `aws_question` ADD KEY ( `published_uid` ); ALTER TABLE `aws_question` ADD KEY ( `answer_count` ); ALTER TABLE `aws_question` ADD KEY ( `question_content` ); ALTER TABLE `aws_question_keyword` DROP INDEX `keyword`; ALTER TABLE `aws_question_keyword` ADD KEY ( `question_id` ); ALTER TABLE `aws_question_keyword` ADD KEY ( `keyword` ); ALTER TABLE `aws_notice` ADD KEY ( `dialog_id` ); ALTER TABLE `aws_notice_dialog` ADD KEY ( `recipient_uid` ); ALTER TABLE `aws_notice_dialog` ADD KEY ( `sender_uid` ); ALTER TABLE `aws_notice_dialog` ADD KEY ( `last_time` ); ALTER TABLE `aws_notice_recipient` ADD KEY ( `recipient_uid` ); ALTER TABLE `aws_notice_recipient` ADD KEY ( `sender_uid` ); ALTER TABLE `aws_notice_recipient` ADD KEY ( `notice_id` ); ALTER TABLE `aws_notice_recipient` ADD KEY ( `dialog_id` ); ALTER TABLE `aws_answer` ADD `force_fold` TINYINT( 1 ) NULL DEFAULT '0' COMMENT '强制折叠'; ALTER TABLE `aws_users_online` CHANGE `last_active` `last_active` INT( 11 ) NULL DEFAULT '0' COMMENT '上次活动时间'; ALTER TABLE `aws_users_online` CHANGE `ip` `ip` BIGINT( 12 ) NULL DEFAULT '0' COMMENT '客户端ip'; ALTER TABLE `aws_users_online` CHANGE `active_url` `active_url` VARCHAR( 255 ) NULL DEFAULT NULL COMMENT '停留页面'; ALTER TABLE `aws_users_online` CHANGE `user_agent` `user_agent` VARCHAR( 255 ) NULL DEFAULT NULL COMMENT '用户客户端信息'; ALTER TABLE `aws_topic_question` ADD KEY ( `topic_id` ); ALTER TABLE `aws_topic_focus` ADD KEY ( `topic_id` ); ALTER TABLE `aws_topic_focus` ADD KEY `topic_uid` ( `topic_id`, `uid` ); ALTER TABLE `aws_topic_experience` ADD KEY `topic_uid` ( `topic_id`, `uid` ); ALTER TABLE `aws_user_follow` ADD KEY `user_follow` ( `fans_uid`, `friend_uid` ); ALTER TABLE `aws_question_focus` ADD KEY `question_uid` ( `question_id`, `uid` ); ALTER TABLE `aws_answer_comments` ADD KEY ( `time` ); ALTER TABLE `aws_question_comments` ADD KEY ( `time` ); DELETE FROM `aws_notification` WHERE `action_type` IN (109, 112); 然后清空 app/upgrade/db/20120720.sql 文件里的内容, 再运行一下升级器

关于作者

calmok 注册会员

这家伙很懒,还没有设置简介

问题动态

发布时间
2012-07-27 17:52
更新时间
2012-07-27 18:12
关注人数
3 人关注

推荐内容

用户名2-7个汉字不够用,我在哪能改长点啊,谢谢你
【分享】允许游客浏览所有回复的修改方法
0.6->1.0升级后,无法进入管理界面, 登录页提示404
为什么我开启Rewrite伪静态后,后来添加的话题和问题都在搜索里搜不到!
小修改,让手机web浏览器下次自动登录。不用每次都填写账号和密码~
哪里有模板卖?除了应用市场那几个
Anwsion 1.1.2,正常安装,后台无法登录
编辑器中的按钮在哪里修改?