NativeErr = -417 Passing Bind Variables to DB2 zOS Using DG4DRDA (Doc ID 1616872.1)

Last updated on JANUARY 18, 2017

Applies to:

Oracle Database Gateway for DRDA - Version 11.2.0.1 and later
Information in this document applies to any platform.

Symptoms

You have a Visual Basic application that calls the Database Gateway for DRDA (DG4DRDA) and passes bind variables.
When using 10.2 TG4DB2 this ran successfully but using 11.2.0.3 DG4DRDA you get the error -

ERROR at line 2:
ORA-28500: connection from ORACLE to a non-Oracle system returned this
message:
[Oracle][ODBC DB2 Wire Protocol driver][UDB DB2 for OS/390 and z/OS]PREPARE
STRING INCLUDES PARAMETER MARKERS AS OPERAND OF SAME OPERATOR.
{HY000,NativeErr
= -417}
ORA-02063: preceding 2 lines from GTW
ORA-02063: preceding 3 lines from DEV11
ORA-02063: preceding 4 lines from GTW


The VB application passes the bind variables as a VARCHAR datatype.
The code causing the problem looks like this -


and fails if the bind variable :CompanySelect is passed as a VARCHAR but works if passed as a CHAR.


 



Cause

Sign In with your My Oracle Support account

Don't have a My Oracle Support account? Click to get started

My Oracle Support provides customers with access to over a
Million Knowledge Articles and hundreds of Community platforms