Binding int64 (SQL_BIGINT) as query parameter causes error during execution in Oracle 10g ODBC

北战南征 提交于 2019-12-01 08:40:45

The Oracle 10g Admin Guide in Appendix G.1 says that the Oracle 10g ODBC driver does not support either SQL_C_SBIGINT or SQL_C_UBIGINT.

Like you, we also find that at run time the SQLExecute() fails. And a call to SQLGetDiagRec() returns nothing, rather than a simple message like "Oracle 10g does not support SQL_C_SBIGINT", . Grr....

Anyway, the Appendix G.1 does not say how you should bind data to send into a table with a column defined like NUMBER(20). So we all have to guess, and use whatever (undocumented) technique works. It would be nice if the Appendix G.1 gave some kind of hint or suggestion as to the "best" way.

If converting the number to a string and then binding works for you, stick with that.

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