From 81ae014f7c870f58cc1888181ad9137a1940d9f5 Mon Sep 17 00:00:00 2001 From: taozi <9108791@qq.com> Date: Tue, 23 Feb 2021 11:25:42 +0800 Subject: [PATCH] =?UTF-8?q?sql=E7=BC=BA=E5=B0=91integral=E5=AD=97=E6=AE=B5?= =?UTF-8?q?=E6=B7=BB=E5=8A=A0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- sql/3.1升级3.2sql.sql | 2 +- sql/sql执行顺序说明.txt | 6 ++++-- sql/yshop3.2.sql | 1 + 3 files changed, 6 insertions(+), 3 deletions(-) diff --git a/sql/3.1升级3.2sql.sql b/sql/3.1升级3.2sql.sql index ff739d43..c4a1f42f 100644 --- a/sql/3.1升级3.2sql.sql +++ b/sql/3.1升级3.2sql.sql @@ -5,7 +5,7 @@ -- ---------------------------- ALTER TABLE yx_store_product ADD COLUMN is_integral tinyint(1) ZEROFILL NULL DEFAULT 0 COMMENT '是开启积分兑换' AFTER is_del; -ALTER TABLE yx_store_product ADD COLUMN integral tinyint(1) ZEROFILL NULL DEFAULT 0 COMMENT '需要多少积分兑换' AFTER is_integral; +ALTER TABLE yx_store_product ADD COLUMN integral int(11) NULL DEFAULT 0 COMMENT '需要多少积分兑换 只在开启积分兑换时生效' AFTER is_integral; ALTER TABLE yx_store_product_attr_value ADD COLUMN integral INT(10) DEFAULT 0 COMMENT '需要多少积分兑换' AFTER seckill_price; diff --git a/sql/sql执行顺序说明.txt b/sql/sql执行顺序说明.txt index 2dc11219..f0977c46 100644 --- a/sql/sql执行顺序说明.txt +++ b/sql/sql执行顺序说明.txt @@ -1,2 +1,4 @@ -1、3.0平滑升级3.1 直接导入3.0升级3.1sql.sql(特别说明:平滑升级只限于没有改过添加过菜单之类的,如果你已经添加了菜单,请自行解决一下) -2、如果是全新下载的直接导入yshop3.1.sql +1、3.0平滑升级3.2 直接导入3.0升级3.1sql.sql再执行3.1升级3.2sql.sql(特别说明:平滑升级只限于没有改过添加过菜单之类的,如果你已经添加了菜单,请自行解决一下) +2、如果你已经是3.1版本了直接执行3.1升级3.2sql.sql即可 +3、如果是全新下载的直接导入yshop3.2.sql +4、注意:操作数据库属于危险行为,请勿用于生产库,请事先做好备份,再执行sql操作!!! diff --git a/sql/yshop3.2.sql b/sql/yshop3.2.sql index cbd4dbdc..b79dfcbd 100644 --- a/sql/yshop3.2.sql +++ b/sql/yshop3.2.sql @@ -2345,6 +2345,7 @@ CREATE TABLE `yx_store_product` ( `temp_id` int(10) NULL DEFAULT NULL COMMENT '运费模板ID', `spec_type` tinyint(1) NULL DEFAULT 0 COMMENT '规格 0单 1多', `is_integral` tinyint(1) UNSIGNED ZEROFILL NULL DEFAULT NULL COMMENT '是开启积分兑换', + `integral` int(11) NULL DEFAULT 0 COMMENT '需要多少积分兑换 只在开启积分兑换时生效', PRIMARY KEY (`id`) USING BTREE, INDEX `is_hot`(`is_hot`) USING BTREE, INDEX `is_benefit`(`is_benefit`) USING BTREE,