ORA-01008: not all variables bound
ORA-01008: not all variables bound
Hi,
We are making use of dotConnect for Oracle 8.4.274.
We have a problem with a merge statement query contains the same variable twice in one query. This generates a 'ORA-01008: not all variables bound' exception. If I rename one instance of this name (so :name becomes :name_) then the exception does not occur anymore. If I change the connection string from direct=true to not direct then the error also disappears. This problem also didn't occur prior to upgrading to 8.4.274 with the exact same query.
Is this a know issue with a known solution? (I would like to simply be able to continue using the same variable name twice in one query)
Regards,
Sieme
We are making use of dotConnect for Oracle 8.4.274.
We have a problem with a merge statement query contains the same variable twice in one query. This generates a 'ORA-01008: not all variables bound' exception. If I rename one instance of this name (so :name becomes :name_) then the exception does not occur anymore. If I change the connection string from direct=true to not direct then the error also disappears. This problem also didn't occur prior to upgrading to 8.4.274 with the exact same query.
Is this a know issue with a known solution? (I would like to simply be able to continue using the same variable name twice in one query)
Regards,
Sieme
-
- Devart Team
- Posts: 2420
- Joined: Wed 02 Nov 2011 09:44
Re: ORA-01008: not all variables bound
We could not reproduce the issue. Please create and send us a small test project with the corresponding DDL/DML scripts that reproduces the issue.
Re: ORA-01008: not all variables bound
The query is rather simple and used to work fine (it still does if you run it in oracle sql developer):
MERGE INTO DataTable dt
USING dual
ON (dt.MD = :md)
WHEN NOT MATCHED THEN
INSERT (dt.MD, dt.Content) VALUES (:md, :content)
This is the devart stack trace
" at Devart.Data.Oracle.cb.d()
at Devart.Data.Oracle.bw.m()
at Devart.Data.Oracle.bw.a()
at Devart.Data.Oracle.m.a(Int32 A_0, ci A_1)
at Devart.Data.Oracle.OracleCommand.InternalExecute(CommandBehavior behavior, IDisposable disposable, Int32 startRecord, Int32 maxRecords, Boolean nonQuery)
at Devart.Common.DbCommandBase.ExecuteDbDataReader(CommandBehavior behavior, Boolean nonQuery)
at Devart.Data.Oracle.OracleCommand.ExecuteNonQuery()
if you change the query to
MERGE INTO DataTable dt
USING dual
ON (dt.MD = :md)
WHEN NOT MATCHED THEN
INSERT (dt.MD, dt.Content) VALUES (:md_, :content)
..it works again with devart.
MERGE INTO DataTable dt
USING dual
ON (dt.MD = :md)
WHEN NOT MATCHED THEN
INSERT (dt.MD, dt.Content) VALUES (:md, :content)
This is the devart stack trace
" at Devart.Data.Oracle.cb.d()
at Devart.Data.Oracle.bw.m()
at Devart.Data.Oracle.bw.a()
at Devart.Data.Oracle.m.a(Int32 A_0, ci A_1)
at Devart.Data.Oracle.OracleCommand.InternalExecute(CommandBehavior behavior, IDisposable disposable, Int32 startRecord, Int32 maxRecords, Boolean nonQuery)
at Devart.Common.DbCommandBase.ExecuteDbDataReader(CommandBehavior behavior, Boolean nonQuery)
at Devart.Data.Oracle.OracleCommand.ExecuteNonQuery()
if you change the query to
MERGE INTO DataTable dt
USING dual
ON (dt.MD = :md)
WHEN NOT MATCHED THEN
INSERT (dt.MD, dt.Content) VALUES (:md_, :content)
..it works again with devart.
-
- Devart Team
- Posts: 2420
- Joined: Wed 02 Nov 2011 09:44
Re: ORA-01008: not all variables bound
We have reproduced the issue. We will investigate it and post here about the results as soon as possible.
Re: ORA-01008: not all variables bound
What is the status on this?
-
- Devart Team
- Posts: 2420
- Joined: Wed 02 Nov 2011 09:44
Re: ORA-01008: not all variables bound
The investigation is in progress. As soon as we have any results, we will post here.
-
- Devart Team
- Posts: 2420
- Joined: Wed 02 Nov 2011 09:44
Re: ORA-01008: not all variables bound
We have fixed the bug with using the same parameter several times in a MERGE statement in the Direct mode. We will post here when the corresponding build of dotConnect for Oracle is available for download.
-
- Devart Team
- Posts: 2420
- Joined: Wed 02 Nov 2011 09:44
Re: ORA-01008: not all variables bound
New build of dotConnect for Oracle 8.4.303 is available for download!
It can be downloaded from http://www.devart.com/dotconnect/oracle/download.html (trial version) or from Registered Users' Area (for users with valid subscription only).
For more information, please refer to http://forums.devart.com/viewtopic.php?t=30900
It can be downloaded from http://www.devart.com/dotconnect/oracle/download.html (trial version) or from Registered Users' Area (for users with valid subscription only).
For more information, please refer to http://forums.devart.com/viewtopic.php?t=30900