I'm on a project using an old version of LLBLGen Pro (1.0.2004.2). We are implementing a mechanism in our application to handle error messages for constraint violations. If a constraint if violated, then we catch the exception, parse out the name of the constraint, and look it up in the database to retrieve a user-friendly error message. This is helpful in centralizing knowledge of what constitutes "valid data" in the database itself.
My question is: short of wrapping each database update in code to look up these error messages, would we be better off catching the exception at a low level within LLBLGen and rethrowing an exception with the friendly message? If so, what template(s) would we need to modify to do this?
Thanks.