在没有示例数据的情况下安装Magento 1.7.0.2时出现SQL错误 [英] SQL Error While Installing Magento 1.7.0.2 Without Sample Data

查看:71
本文介绍了在没有示例数据的情况下安装Magento 1.7.0.2时出现SQL错误的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

在没有示例数据的情况下安装magento 1.7.0.2时,出现以下错误

While installing magento 1.7.0.2 without sample data I'm getting the following error

Blockquote 文件中的错误:"C:\ wamp \ www \ magentojs \ app \ code \ core \ Mage \ SalesRule \ sql \ salesrule_setup \ upgrade-1.6.0.0-1.6.0.1.php"-SQLSTATE [42000]:语法错误或访问违规:1067期间"的默认值无效

Blockquote Error in file: "C:\wamp\www\magentojs\app\code\core\Mage\SalesRule\sql\salesrule_setup\upgrade-1.6.0.0-1.6.0.1.php" - SQLSTATE[42000]: Syntax error or access violation: 1067 Invalid default value for 'period'

是否有已知的解决方案?

Is there a known solution for this?

推荐答案

在install-1.6.0.0.php中,您拥有

in install-1.6.0.0.php you have

->addColumn('period', Varien_Db_Ddl_Table::TYPE_DATE, null, array(
'nullable' => false,
), 'Period')

提供一个默认值,表示将上面的代码替换为

provide a default value that means replace above code by

->addColumn('period', Varien_Db_Ddl_Table::TYPE_DATE, null, array(
'nullable' => false,
'default' => '0000-00-00',
), 'Period')

这篇关于在没有示例数据的情况下安装Magento 1.7.0.2时出现SQL错误的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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