Fix for truncation of strings with FreeTDS driver#22
Fix for truncation of strings with FreeTDS driver#22jbaxter0810 wants to merge 1 commit intowankdanker:masterfrom
Conversation
Added a fix for FreeTDS. It was interpreting stings longer than 4000 characters as NVARCHAR(4000) instead of NVARCHAR(MAX). Update so now it interprets strings longer than 4000 characters as SQL_WLONGVARCHAR
|
If memory serves correctly, I think there are some weird issues surrounding the usage of SQL_WLONGVARCHAR. I need to do some research. |
|
Yeah, see #10. Need to figure out how to solve this problem for good. |
|
Yeah, it's a horrible problem. I don't know if there is a sane solution :( |
|
I think this is going to require some kind of config property with specific code for each driver--ugly, but probably necessary because I doubt there are ways to accurately detect the behavior here. A couple ideas:
|
|
I agree, @bzuillsmith. Even if we can accurately detect what the proper type should be either from the driver or other magic, we'll have to have a property on the connection that can be passed to We could also expose methods to manually set up the bindings (as @lee-houghton did in eos) where the user can manually set the data types, sizes, etc instead of trying to just magically do the right thing. |
Adding support for Node.js Buffer class to send binary data
Added a fix for FreeTDS. It was interpreting strings longer than 4000
characters as NVARCHAR(4000) instead of NVARCHAR(MAX). Updated so now it
interprets strings longer than 4000 characters as SQL_WLONGVARCHAR instead of SQL_WVARCHAR.