--mysql 触发器简单实例
--创建表1
create table tab1(t1_id varchar(20)) ;
--创建表2
create table tab2(t2_id varchar(20));


--创建触发器,表一增加数据时,表二自动增加数据 create trigger t_afterinsert_on_tab1 after insert on tab1 for each row begin insert into tab2(t2_id) values (new.t1_id); end;

 

相关文章:

  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2021-12-17
  • 2022-12-23
  • 2021-04-09
  • 2022-01-10
  • 2021-11-22
猜你喜欢
  • 2021-12-22
  • 2021-05-23
  • 2021-08-12
  • 2022-12-23
  • 2022-12-23
  • 2021-12-15
  • 2022-12-23
相关资源
相似解决方案