🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: borland.public.interbase.sql
Article #44

exception strange behavior

#44
From: Isaac
Date: Fri, 23 May 2008 14:41
18 lines
1598 bytes
Hello,
I am facing a strange behavior when raising an exception from inside a 
stored procedure

I have three triggers that call one stored proc after insert , after 
update and after delete

I check in the stored proc if a bal is < 0 if so then I raise an exception

I also had to do the same check in my app so I can make sure bal is 
never < 0, so the result was one time the store exception is fired 
immediately after insert a record but all other tries never raised again 
and only my application check exception is the one that always raised 
although I made the check in a save button after the user inserted as 
many item as he want

Please advice why the stored exception did not raised first !!
Thanks
Technical Details
Message-ID: <4836d7b3@newsgroups.borland.com>
Path: arc1-ca.pugleaf.net!g2news1.google.com!news2.google.com!border1.nntp.dca.giganews.com!border2.nntp.dca.giganews.com!nntp.giganews.com!newspeer1.nac.net!newsfeeds.ihug.co.nz!ihug.co.nz!newsgroups.borland.com!not-for-mail

Show Full Headers
Complete Article Headers
X-Google-Thread: 114a0e,c20e0dc1cd267813,start
X-Google-Attributes: gid114a0e,domainid0,public,usenet
X-Google-Language: ENGLISH,ASCII-7-bit
Date: Fri, 23 May 2008 17:41:49 +0300
From: Isaac <no@no.com>
User-Agent: Thunderbird 2.0.0.14 (Windows/20080421)
MIME-Version: 1.0
Newsgroups: borland.public.interbase.sql
Subject: exception strange behavior
Content-Type: text/plain; charset=ISO-8859-1; format=flowed
Content-Transfer-Encoding: 7bit
NNTP-Posting-Host: 41.234.200.242
Message-ID: <4836d7b3@newsgroups.borland.com>
X-Trace: newsgroups.borland.com 1211553715 41.234.200.242 (23 May 2008 07:41:55 -0700)
Lines: 18
Path: arc1-ca.pugleaf.net!g2news1.google.com!news2.google.com!border1.nntp.dca.giganews.com!border2.nntp.dca.giganews.com!nntp.giganews.com!newspeer1.nac.net!newsfeeds.ihug.co.nz!ihug.co.nz!newsgroups.borland.com!not-for-mail
X-Original-Bytes: 1425