You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Using Microsoft.Data.SqlClient, when I pass a TVP along with any other parameters into an MSSQL Stored Procedure I receive an error that the other parameter does not exist, even though when debugging, it clearly exists and was assigned to the command. If I change the Stored Procedure/code and pass a TVP to a stored procedure without any other parameters it appears to work fine.
In my opinion, you should be able to pass other individual parameters along with a TVP into a Stored Procedure as to not need to duplicate fixed data inside of the TVP itself. This appears to be different from the older System.Data.SqlClient, and does not work with the newer Microsoft.Data.SqlClient package.
Thanks for the quick response. I'll need to put together something and unfortunately I'm under a bit of a deadline right now/it will take a few days to build out something. Thanks again. I'll need to double check but I'm fairly certain this is different behavior from the previous version.
Activity
ErikEJ commentedon Oct 25, 2022
Please share a runnable repo. There should be no difference between the two drivers.
briantheusch commentedon Oct 25, 2022
Thanks for the quick response. I'll need to put together something and unfortunately I'm under a bit of a deadline right now/it will take a few days to build out something. Thanks again. I'll need to double check but I'm fairly certain this is different behavior from the previous version.
JRahnama commentedon Oct 25, 2022
@briantheusch as @ErikEJ mentioned, a repro would help us a lot to understand the situation.
briantheusch commentedon Oct 26, 2022
Disregard - this was a unintentional bug in my code. I apologize and thank you again for the prompt response.