插入触发器:
DELIMITER $$
CREATE TRIGGER `dede_sys_enum_AINS`
BEFORE INSERT ON dede_sys_enum
FOR EACH ROW
begin
set new.father=replace(new.evalue,new.evalue,FLOOR(new.evalue/500)*500);
end
插入触发器:
DELIMITER $$
CREATE TRIGGER `dede_sys_enum_AINS`
BEFORE INSERT ON dede_sys_enum
FOR EACH ROW
begin
set new.father=replace(new.evalue,new.evalue,FLOOR(new.evalue/500)*500);
end