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
Is your feature request related to a problem? Please describe.
When you try to BulkCopy a too large string, you receive following error from here:
System.InvalidOperationException: String or binary data would be truncated.
This message is "faked" by the managed code to look like the message sql server sends.
A year ago, this message is now available in an improved form, at least if the exception is actually thrown by MSSQL.
Describe the solution you'd like
Please make similiar improvements (column and value affected) to the managed exception.
Describe alternatives you've considered
If you can attach a debugger, you can enable first chance exception breaking for InvalidOperationException, then you'll see the string that was too long when you look in the locals window of the throwing stack frame. But this is only applicable when you can debug it.
The text was updated successfully, but these errors were encountered:
then you'll see the string that was too long when you look in the locals window of the throwing stack
Can you see fhe field definition it was supposed to be put in? and by seeing it do you mean that you as a problem solving human recognise it as invalid or that all the information is present for a dumb computer to report it as you ask? If so it sounds like it would be easy enough to change.
Yes it seems everything is there, object value contains the string and metadata.column contains the column name. MaxLength is available as metadata.length / 2
Is your feature request related to a problem? Please describe.
When you try to BulkCopy a too large string, you receive following error from here:
This message is "faked" by the managed code to look like the message sql server sends.
A year ago, this message is now available in an improved form, at least if the exception is actually thrown by MSSQL.
Describe the solution you'd like
Please make similiar improvements (column and value affected) to the managed exception.
Describe alternatives you've considered
If you can attach a debugger, you can enable first chance exception breaking for
InvalidOperationException
, then you'll see the string that was too long when you look in the locals window of the throwing stack frame. But this is only applicable when you can debug it.The text was updated successfully, but these errors were encountered: