-
Notifications
You must be signed in to change notification settings - Fork 435
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
About “The incoming tabular data stream (TDS) remote procedure call (RPC) protocol stream” #171
Comments
Can you provide a Minimal, Complete, and Verifiable example? |
Hi,thanks for your response,next is my example:
I found the problem is at "new BigDecimal(0.0000).setScale(4,BigDecimal.ROUND_HALF_UP)",the precision is four and the value is 0.0000,it will throws that exception.Eagerly looking forward to your reply. |
I can reproduce the issue using the above Java code along with CREATE TYPE [dbo].[TVP_TbaleA] AS TABLE(
[c1] [decimal](18, 4) NOT NULL,
[c2] [decimal](18, 4) NULL,
PRIMARY KEY CLUSTERED
(
[c1] ASC
)WITH (IGNORE_DUP_KEY = OFF)
) and CREATE PROCEDURE [dbo].[spT_TbaleA_i]
@tbl dbo.TVP_TbaleA READONLY
AS
BEGIN
SET NOCOUNT ON;
SELECT c1 + c2 AS cSum FROM @tbl;
END As decribed, it is the new BigDecimal(0.0000).setScale(4,BigDecimal.ROUND_HALF_UP) argument to new BigDecimal(1.0000).setScale(4,BigDecimal.ROUND_HALF_UP) and new BigDecimal(0.0000) work fine. |
@rabbit-mom which version of the driver do you use? could you please try with a newer version? This bug seems to be fixed since 6.1.2 |
My repro above was with the latest production release: 6.0.8112.100 Re-tested with version 6.1.4 and the error did not occur, so this appears to be the same issue as #92. |
@gordthompson thank you for getting back to us and confirming with us. I am going to close this issue then. @rabbit-mom please free feel to re-open the issue if you see this issue again with newer version of the driver. Thank you. |
Thank you very much, the problem has been resolved. |
when I using TVP to bulkinsert to a table,this exception occured,and I do not konw to solve it?
"com.microsoft.sqlserver.jdbc.SQLServerException: The incoming tabular data stream (TDS) remote procedure call (RPC) protocol stream is incorrect. Table-valued parameter 0 (""), row 0, column 0: Data type 0x6C has an invalid precision or scale."
What reason is this?How to solve it?
The text was updated successfully, but these errors were encountered: