DB2异常处理 [英] DB2 Exception handling
问题描述
PS:我有一个存储过程用于此迁移,我没有使用任何其他语言来调用它。
<我们可以通过oracle中的SQLERRM来实现;可能这应该是一件小事,还有一些奇怪的原因我还没有找到它!
希望你对此有一个想法;-)。我只需要一个指针。
谢谢,
Harveer Uppal
您应该可以使用 DB2Exception.Message 属性。
The problem that I am facing is primarily on Exception Handling! When an exception occurs I want to put that data in another log table with the error message. However, in DB2 I am not able to figure out a way to retrieve the corresponding error message for the raised SQLSTATE.
PS: I have a stored procedure for this migration and I am not using any other language to call it.
We could do this through SQLERRM in oracle; probably it should be a small thing, still for some strange reasons I have not been able to find it yet!
Hopefully you would have an idea on this, ;-). I just need a pointer on this.
Thanks,
Harveer Uppal
You should be able to get in the front-end code using DB2Exception.Message property.
这篇关于DB2异常处理的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!