Re: Error Handling Coming Out of a Trigger



"Brian Hollister" <bhollisterATfuturaintlDOTcom> wrote in message
news:46798b8f@xxxxxxxxxxxxxxxxxxxxxxxxx
Try raising the exception, then rolling back the transaction.


That's weird. I swear I've done that and it (raising an exception from
inside a trigger) worked just fine. I'll dig around and see what I can
find.

That did not work, but thank you though. What I have decided to do is to
separate the business rule enforcement from the database and try to allow
the database to just maintain data integrity through keys and constraints
and not forced logic, as much as possible. Kevin, I got this idea from a
conversation you and two other guys were having. I googled it up in
groups...

Did you go this way as well? If so, are you happier with it?


In some/most cases yes and so far so good. From what I see you are needing
to do, a trigger might be the ideal solution and should be working just as
you expect.

For a little nostalgia, do you have a link of that conversation?

krf


.



Relevant Pages

  • Re: Error 2950 - Reserved Error on form refresh/requery
    ... and I can't leave the client with an unusable database while I try to ... The requery is on the form (so the data displayed in the sub-forms refreshes ... The triggering event is a listbox after update that does 2 things only: ... can trigger others, and so the problem may occur only when a specific ...
    (microsoft.public.access.formscoding)
  • Re: Help with INSERT TRIGGER - fails with error.
    ... You didn't declare any PRIMARY KEY in this database. ... In an INSERT trigger, ... but I can't get it to work because it references ntext fields. ...
    (comp.databases.ms-sqlserver)
  • "on exception" statement not firing within stored procedure when called from trigger
    ... I am experiencing a problem whereby ON EXCEPTION statements are ... not firing within stored procedures when the stored procedures ... are invoked from a trigger. ... create table tBar ) lock mode row; ...
    (comp.databases.informix)
  • Re: Lookup Tables, the right way?
    ... model is comes in un-learning what you know about file systems. ... The users might not all have the same database access rights ... This rule would be enforce by a REFERENCES ... with a trigger that you can do with DRI and more. ...
    (comp.databases.theory)
  • Re: Using one table vs. many
    ... model is comes in un-learning what you know about file systems. ... The users might not all have the same database access rights ... This rule would be enforce by a REFERENCES ... with a trigger that you can do with DRI and more. ...
    (comp.databases)