Dapper icon indicating copy to clipboard operation
Dapper copied to clipboard

with string > 4000 characters fails against DM8(达梦数据库)

Open itwmike opened this issue 3 years ago • 0 comments

Writing a string longer than 4000 bytes to an text class property fails with an obscure error (index size -1). Writing a string of 3999 bytes is fine. I know it can be solved by DynamicParameters(https://github.com/DapperLib/Dapper/issues/212) But there are a lot of INSERT fields and a lot of code,Are there other better solutions?

Can I set sieze equal to 0 ,Or use string length

向文本类属性写入超过4000字节的字符串将失败,并出现一个模糊错误(索引大小-1)。写入3999字节的字符串是可以的。 我知道它可以通过DynamicParameters(https://github.com/DapperLib/Dapper/issues/212)解决 但是INSERT时有很多字段,会产生很多代码,有没有更好的解决方案? 我可以设置size等于0,或者让它等于值的长度吗?

itwmike avatar Sep 02 '22 09:09 itwmike