How to catch DB errors?

Hello,

does anyone know how I can prevent database errors? Let’s say you have a column specified as “not null” and the user leaves the field empty, an error is thrown. This error is not something every user understands. So I would like to catch that error and present something the user understands.

I have played with error capture in combination with onRecordSave, but no success. Does anyone have a solution for this?

Thanks
Patrick

we are looking at better error reporting our self.
(with error codes ect)
Databases errors (codes) are not really in a standard format..
So we have to first do that ourselfs.

if we could grab the error that servoy throws ("Java … SQL Server message … ") we’d be able to interpret what went wrong ourselfes. But I see no way to get that error…

that is for every database different.. and there are a lot of different error messages that you could get…

but is it possible to “deliver” whatever error to us?