Closed maxtoroq closed 10 years ago
Added SQL.Param method to workaround this issue, e.g.:
byte[] imageData = GetImageData();
var update = SQL
.UPDATE("images")
.SET("content = {0}", SQL.Param(imageData))
.WHERE("id = {0}", id);
Cannot find SQL.param in latest code ?? Has it been removed? I am having trouble adding the byte[] array
ArgumentException: No mapping exists from object type System.Int64[] to a known managed provider native type.
SQL.Param
was dropped in v6. Arrays are no longer special. To expand an array into a list you must call SQL.List
.
And this also applies to byte[] when the field is a concurrency field?
No, it shouldn't. Perhaps if you show me some code I can help.
Same code as at the top of here #39
Looks like a provider issue. If System.Int64[]
is the type of the parameter, looks like the provider is getting the same type but for some reason not liking it.
NOTE: In v6, this is no longer an issue. For more information see SqlBuilder Tutorial: Lists.
e.g.
Need to workaround parameter expansion, like this: