Divide by zero, app does NOT crash?
Posted in 1998
Topics: Connectivity: ESQL/C, 4GL & Embedded SQL
Dear all, I guess that not very often you see someone complaining about app not crashing, but... My client have an 4gl app, c-compiled, some external c functions. Error log is full of entries like this: FORMS statement error number -1202. An attempt was made to divide by zero. No line number, no sourcefile name. I was expecting that divide by zero will unconditionally stop the app, but, it seems that this is not the case. There are at least 50 entries like that a day, and I am unable to trace them. Is it possible that this error can be the result of the SQL statement that is trying to divide by zero, and because it happens in the engine, it does not kill the app? And most of all, how to trace this, if the app does not crash? BTW, no debugger there. TIA, Andrej #include<std.disclaimer.h> **************************************************************** * Andrej Falout, RDBMS R&D, Croatia, Europe, afalout@zg.tel.hr * * ICQ: 7628616 http://wwp.mirabilis.com/7628616 * *--------------------------------------------------------------* * "To develop with a 4GL, the developer does not have to be an * * expert programmer." - John McNally, "Informix Unleashed" * **************************************************************** Last seen: Eating Kiwis down under (AKA afalout@ihug.co.nz)
Since upgrading from SE 4.10 to 4.20 I am getting similar Informix error log entries with "integer/money value exceeds precision" messages with no source file name or line number. The user doesn't see anything amiss, although in one diagnosed example the cursor stopped in a screen field for a couple of seconds (at which point when the message was written) before continuing as if nothing had happened. Interesting feature. In article <366b460e.68484445@news.ihug.co.nz>, Andrej Falout <afalout@ihug.co.nz> writes >Dear all, > >I guess that not very often you see someone complaining about app not crashing, >but... > >My client have an 4gl app, c-compiled, some external c functions. > >Error log is full of entries like this: > > FORMS statement error number -1202. > An attempt was made to divide by zero. > >No line number, no sourcefile name. > >I was expecting that divide by zero will unconditionally stop the app, but, it >seems >that this is not the case. There are at least 50 entries like that a day, and I >am >unable to trace them. -- Steve Williamson
>Since upgrading from SE 4.10 to 4.20 I am getting similar Informix error >log entries with "integer/money value exceeds precision" messages with >no source file name or line number. > >The user doesn't see anything amiss, although in one diagnosed example >the cursor stopped in a screen field for a couple of seconds (at which >point when the message was written) before continuing as if nothing had >happened. If you are running a 4gl app check the error trapping - make sure it's WHENEVER ANY ERROR ... , without the 'any' a form or overflow error will be reported only.