IBM DB2 for i error messages using short column names in errors

只谈情不闲聊 提交于 2019-12-23 20:19:02

问题


Note this question is specific to "IBM DB2 for i", the IBM i operating system's version of DB2.

The below screenshot shows a purposely erroneous INSERT statement that produces an SQL error of SQL0407.

My question... Is there a DB2, JDBC, or other setting I can alter so the long column names are used in the error vs. the cryptic short ones? Note I used the long column names in the INSERT statement.


回答1:


Carol Ramler, DB2 for i Senior Software Engineer at IBM, responded with this:

In this situation it is the low level database manager code that is generating the error and it does not fill in the long column name due to historical and performance reasons.

Given her title I trust she is right :-)




回答2:


After looking over the JDBC properties documentation on InfoCenter ... Have you tried the JDBC properties of "errors"="full" and/or "extended metadata" = "true"?



来源:https://stackoverflow.com/questions/20076569/ibm-db2-for-i-error-messages-using-short-column-names-in-errors

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!