Whats happen...yes or not....??????????????????????'
best regards
MIguel
------------------------------------------------------------
I saw couple of suggestions using SP, infact you can get it done in trigger
itself, the uasge is as below :
create trigger example1insert on tab_1 referencing new as not_old
for each row when (a=1) (execute spl_1()), -- Notice this use of "," to
continue
when (a=2) (execute spl_2()); -- Notice this use
of ";"
to finish.
Hope this helps you.
--
Have a nice day
Felix K. Mathews
mailto:fmathews@systems.dhl.com
----------
} De: sujata_soman_at_omm-la2-infotech-001@internet.omm.com
} A: informix-list@rmy.emory.edu; joschneidr@aol.com (JoSchneidr)
} Asunto: Re: Multiple "When" in Trigger
} Fecha: Thursday 16 de October de 1997 19:45
}
}
} Hi.
} No, you cannot have multiple "when" in a trigger. Your best bet
} would be to create a stored procedure with the "if" clause and then
} called this stored procedure inside the trigger.
} I had the same problem. Check the manual, it only allows for a
} single "when" clause.
}
} Hope that helps.
}
} Sujata
}
}
} ______________________________ Reply Separator
_________________________________
} Subject: Multiple "When" in Trigger
} Author: <joschneidr@aol.com (JoSchneidr)> at internet
} Date: 10/16/97 5:25 PM
}
}
} Hy out there,
} my question may sound strange but is there a possibility to have more
} then one WHEN-Condition in a trigger ?
}
} I tried out something like this :
}
} create trigger example1
} insert on tab_1 referencing new as not_old
} for each row when (a=1) (execute spl_1());
} when (a=2) (execute spl_2());
}
} I tried out multiple version with changing syntax but there is always a
syntax
} error
} after the first "when" condition.
}
} Any help would be appreciated.
}
}
}
}