drop trigger if exists tr_crs_tabledata551;
Create trigger tr_crs_tabledata551
after delete on crs_tabledata551 for each ROW
begin
delete from crs_tabledata552 WHERE id = old.id ;
end ;
DELIMITER ;错误
SQL 查询: CREATE trigger tr_crs_tabledata551 AFTER DELETE ON crs_tabledata551 FOR each ROW BEGIN DELETE FROM crs_tabledata552 WHERE id = old.id;MySQL 返回: #1064 - You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '' at line 4
mysqlsql
Create trigger tr_crs_tabledata551
after delete on crs_tabledata551 for each ROW
begin
delete from crs_tabledata552 WHERE id = old.id ;
end ;
DELIMITER ;错误
SQL 查询: CREATE trigger tr_crs_tabledata551 AFTER DELETE ON crs_tabledata551 FOR each ROW BEGIN DELETE FROM crs_tabledata552 WHERE id = old.id;MySQL 返回: #1064 - You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '' at line 4
mysqlsql
drop trigger if exists tr_crs_tabledata551;
Create trigger tr_crs_tabledata551
after delete on crs_tabledata551 for each ROW
begin
delete from crs_tabledata552 WHERE id = old.id ;
end
$
DELIMITER ;
但是很奇怪我放入PHPMYADMIN中执行,就卡住了,MYSQL也没返回结果,很奇怪。
DELIMITER //
Create trigger tr_crs_tabledata551
after delete on crs_tabledata551 for each ROW
begin
delete from crs_tabledata552 WHERE id = old.id ;
end ;
//
DELIMITER ;
DELIMITER$
Create trigger tr_csc_tabledata551
after delete on crs_tabledata551 for each row
begin
delete from crs_tabledata552 where id=old.id;
end$
DELIMITER;
mysql> Create trigger tr_crs_tabledata551
-> after update on crs_tabledata551 for each ROW
-> begin
-> update a set memo = '100' where id = new.id;
-> end ;
-> //
ERROR 1227 (42000): Access denied; you need the SUPER privilege for this operati
on
mysql> DELIMITER ;
mysql> $
-> ;