For a SQL statement, I can get the SQLSTATE and then use GET DIAGNOSTICS EXCEPTION to get the message text. Is there any extended details that I can retrieve?

This comes up occasionally. The current instance is SQLSTATE 22018 "Character in CAST argument not valid". The obvious question is "CAST exception on what?". Currently I do it like the dark ages of checking Christmas lights, check every bulb until you find the bad one. I'm hoping there's a better way I just haven't learned yet.


TIA

As an Amazon Associate we earn from qualifying purchases.

This thread ...

Follow-Ups:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2022 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.