-
Notifications
You must be signed in to change notification settings - Fork 426
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Misleading SQLServerException: The value is not set for the parameter number N #1059
Comments
Hi @cnsgithub, thanks for making the team aware of the issue and providing a detailed reproduction. I've managed to replicate the issue described in this thread and will look into it. |
Fixed in #1064 |
What was the solution? |
@ulvii I get an Exception that says: |
Hi @Nikitomas, What version of the driver are you using? |
If you still have this issue, please feel free to open a new issue. We prefer having new issues opened as opposed to commenting on closed issues. Thanks! |
Driver version
7.2.2.jre11 (also tested with 7.0.0.jre10)
SQL Server version
Microsoft SQL Server 2017 (RTM-CU9-GDR) (KB4293805) - 14.0.3035.2 (X64) Jul 6 2018 18:24:36 Copyright (C) 2017 Microsoft Corporation Enterprise Edition: Core-based Licensing (64-bit) on Windows Server 2019 Standard 10.0 <X64> (Build 17763: ) (Hypervisor)
Client Operating System
Windows 10
JAVA/JVM version
JDK 11
Table schema
Problem description
When calling a stored procedure with at least two parameters from JDBC under insufficient rights, the error message is misleading.
SQLServerException
with messageThe EXECUTE permission was denied on the object 'test'
SQLServerException
with messageThe value is not set for the parameter number 2.
Similar issue: Misleading SQLServerException: Parameter was not defined for stored procedure #608.
JDBC trace logs
n/a
Reproduction code
I created a small github repo to reproduce the issue: https://github.com/cnsgithub/sqljdbc. Just clone the repo, setup the DB schema and execute the unit test using plain JDBC.
The text was updated successfully, but these errors were encountered: