MSS Stored procedure call "Must declare @p0"

Discussion of open issues, suggestions and bugs regarding usage of ODBC Drivers
Post Reply
Posts: 1
Joined: Fri 06 Oct 2017 15:53

MSS Stored procedure call "Must declare @p0"

Post by dgood » Fri 06 Oct 2017 16:00

SQL Server : 2016

I am evaluating the driver and hoping to move to DEVART ODBC driver from SQL Server ODBC driver (V13) to improve performance of application.

The following code works fine with SQL Server ODBC driver, but not with DEVART.

Im using ODBC to call a stored procedure as follows

Code: Select all


SQLBindParameter return value (OUTPUT)
SQLBindParameter X 3 for INPUT PARAMS
SQLBindParameter for last OUTPUT parameter

SQLExecDirect("{? = call MYPROC(?,?,?,?)}");
At SQLExecDirect, I get message

"[Devart][ODBC][Microsoft SQL Server]Must declare the scalar variable "@p0"."

Im not using a @p0.
Any ideas on what might cause this.


Devart Team
Posts: 1119
Joined: Fri 11 Apr 2014 11:47
Location: Alpha Centauri A

Re: MSS Stored procedure call "Must declare @p0"

Post by azyk » Tue 10 Oct 2017 07:53

Thank you for the information.

We reproduced the specified issue and fixed it. This fix will be included in the next build of our driver. If you want to get this fix before the official release, use the contact form at our site: and send us the email address where we can send a night build of the driver.

Post Reply