当前位置:Gxlcms > 数据库问题 > mysql 更新数据

mysql 更新数据

时间:2021-07-01 10:21:17 帮助过:20人阅读

drop PROCEDURE IF EXISTS AddIsDoliday ; 2 CREATE PROCEDURE AddIsDoliday() 3 BEGIN 4 IF NOT EXISTS (SELECT * FROM information_schema.columns WHERE table_schema = DATABASE() AND table_name = t_fee_static AND column_name = IsDoliday) THEN 5 ALTER TABLE t_fee_static ADD IsDoliday int(4) DEFAULT 0 COMMENT 是否节假日(1:是;0否;) AFTER ticketTimeType; 6 END IF; 7 IF NOT EXISTS (SELECT * FROM information_schema.columns WHERE table_schema = DATABASE() AND table_name = t_fee_type AND column_name = IsDoliday ) THEN 8 ALTER TABLE t_fee_type ADD IsDoliday int(4) DEFAULT 0 COMMENT 是否节假日(1:是;0否;) AFTER IsDelete; 9 END IF; 10 11 end ; 12 call AddIsDoliday(); 13 drop PROCEDURE IF EXISTS AddIsDoliday;

 

mysql 更新数据

标签:exist   sch   procedure   blog   and   mysq   mat   roc   format   

人气教程排行