[Info-ingres] User friendly error message on constraint violation

Martin Bowes martin.bowes at ndph.ox.ac.uk
Wed Apr 8 07:20:40 UTC 2020


Hi Nikos,

You can't alter the message the constraint provides.

You're only alternative is to replace the constraint with a Rules Fired Procedure which does much the same thing. With an RFP you can make whatever message you like.

Marty

-----Original Message-----
From: nikosv <nikos.vaggalis at gmail.com> 
Sent: 07 April 2020 22:59
To: info-ingres at lists.planetingres.org
Subject: [Info-ingres] User friendly error message on constraint violation

I have a check constraint that when fired displays "check integrity constraint violates "check_covid_test" on table test was violated"
Now that doesn't help the user at all.Is there a way to catch it and instead display a nice user friendly error? Application is ABF/4GL.Or even in general how to handle such cases.
_______________________________________________
Info-ingres mailing list
Info-ingres at lists.planetingres.org
https://lists.planetingres.org/mailman/listinfo/info-ingres



More information about the Info-ingres mailing list