Hi,
Im having a problem with the SQL Server 2005 JDBC Driver v1.1, when it throws a BatchUpdateException it is not setting the vendor-specific error code! It is always returning zero for the error code. The exception is being thrown due to a Unique key contraint. It should be throwing the error codes ( 2627 or 2601 ) which were thrown by the SQl Server 2000 driver.
Can anyone explain?
Hi,
Let me research this and get back to you. It looks like it may be a bug in the 2005 driver. What driver version are you using (output from DatabaseMetaData.getDriverVersion())?
Thanks,
--David Olix (MSFT)
|||Hi David,
The driver version is 1.1.1501.101
Thanks again,
Cathal
|||
Ok, thanks. Two more questions for you then:
1. Does this behavior happen only when the key violation occurs on the first (or only) statement in the batch?
2. Are you seeing the behavior with Statement, but not PreparedStatement or CallableStatement?
If the answer is 'yes' to both of these then I believe it's a bug that we are currently targetting to fix in the next JDBC driver release around mid-year.
If that's not the problem, then you may may want to contact Microsoft Customer Support (support.microsoft.com) for further assistance.
Thanks again,
--David Olix (MSFT)
|||Hi David,
Thanks again for your reply. Our tests can confirm the behaviour you have outlined above. Could you give me some more detail about this bug, a tracking number etc? Just so we can keep track of it from our end.
Thanks,
Cathal
|||Hi David,
Thank you for your help with this issue. Would you be able to confirm my previous request for a bug tracking number for this issue. We are keeping track of it from our end and would like to close this issue as soon as possible.
Thanks again,
Cathal
|||Hi Cathal,
Sorry for not catching your previous post. I'm not quite sure what kind of tracking number you are requesting. We don't maintain a bug database for public reference. Would an internal bug tracking number help you any? Alternately, if you open a support case with Customer Support (support.microsoft.com), they will provide you with a case number that you can use for tracking. They may also be able to provide you with an unsupported interim build that contains the fix for development and testing purposes -- not for production. The fix will also be in the publicly available v1.2 CTP1, currently targeted for April.
Thanks again for your continued interest in this driver,
--David Olix [MSFT]
没有评论:
发表评论