想向表格插入一条insert into students values(NULL, "王刚", "男", 20, "13811371377");提示table doesn't exist。 而且我想把表格student,students中的student删除,用drop student命令删不了,提示出错。
你用的数据库不是之前创建表所在的数据库了,就会提示表不存在。参考技术AUSE `test`; DELIMITER $$ DROP TRIGGER IF EXISTS test.desktop_test_AFTER_INSERT$$ USE `test`$$ CREATE DEFINER = CURRENT_USER TRIGGER `test`.`desktop_test_AFTER_INSERT` AFTER INSERT ON `desktop_test` FOR EACH ROW begin set @tv=1000 ; set @newdate=new.cdate ; set @newh=new.h ; insert into check_log_test select cdate,h,(case when pv_pc<=@tv then 1 else 0 end),pv_pc from desktop_test where cdate=@newdate and h=@newh ; end; DELIMITER ;