thanx it works the trigger is created successfully but it has no
effect. here it is:
delimiter //
create trigger testref before insert on bookmarks
for each row
begin
declare dummy char(2);
if new.title like '%xxx%'
then
set new.id='xxx';
end if;
end;
//create trigger testref before insert on bookmarks
-> for each row
-> begin
-> declare dummy char(2);
-> if new.title like '%xxx%'
-> then
-> set dummy = 'xxx';
-> end if;
-> end;
-> //
then:
insert into bookmarks values (1, "xxxxx");
Query OK, 1 row affected, 1 warning (0.00 sec)
the row is created with a warning. I would like to prevent it from
being created. I would like the insert to be canceled if the value is
equal to xxx.
any idea how to cancel the insert?
thanx in advance
Pat
--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe: http://lists.mysql.com/[EMAIL PROTECTED]