huanxuan163
2017-04-07 01:53Mysql的触发器这样写有什么问题
create trigger positions_trigger
after update on student_positions for each row
begin
if new.hire_status==1 then
update positions p
set people_approved=people_approved+1
where new.position_id=p.pid
end if;
end
- 点赞
- 回答
- 收藏
- 复制链接分享
1条回答
为你推荐
- 创建MySQL触发器时出错
- mysql
- php
- 1个回答
- 有没有办法通过mysql中的触发器指定更新哪个列?
- sql
- mysql
- php
- 1个回答
- MySQL会话变量在触发器中的功能
- mysql
- php
- session
- 1个回答
- 使用php更改mysql触发器中的值?
- mysql
- php
- 1个回答
- MySQL触发器在插入多次之前检查值
- mysql
- php
- 1个回答
换一换