The dapper supports both list parameters and ansi strings, but if I have a list
parameter of ansi string, then it will fail.
ex: conn.Query<int>("select f1 from t1 where f1 in @f1s",
new { f1s = new DbString[] { new DbString { IsAnsi = true, ...}, ... }});
then it will throw ArgumentException: No mapping exists from object type
Dapper.DbString to a known managed provider native type.
It seems a bug in PackListParameters function, if the input is
IEnumerable<DbString>, it should call (item as DbString).AddParameter instead
just set listParam.Value to item.
Original issue reported on code.google.com by bigsan.c...@gmail.com on 10 Nov 2011 at 10:49
Original issue reported on code.google.com by
bigsan.c...@gmail.com
on 10 Nov 2011 at 10:49