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
{{ message }}
Repository navigation
Does not appear to work with QueryMultiple and .Read<> #43
When using Dapper QueryMultiple, it appears the mapped columns are not working.
In my case QueryMultiple returns 3 tables.
var ds = con.QueryMultiple("uspSELNodes", p, commandType: CommandType.StoredProcedure);
var rows = ds.Read().ToDictionary(v => v.RowNo); //Returns a dynamic dictionary
var total = ds.Read<int>().First(); //Returns table 2 that contains just an int for a total
var columns = ds.Read<DynamicTable.Column>(); // Does not seem to map properly.
Class is as below :
public class Column : IDynamicTableColumn
{
public string Prefix { get; set; }
public string Name { get; set; }
public string DisplayName { get; set; }
public int Order { get; set; }
public bool Orderable { get; set; }
public bool Filterable { get; set; }
public int Width { get; set; }
public string ResourceName { get; set; }
}
The columns that match name for name for example DisplayName all get their correct values from Dapper, the mapped columns appear to be getting the defaults for their type, strings empty, bools false and ints 0.
Activity
cpisto commentedon Aug 11, 2016
I'm seeing something similar with multi-mapping as well. Could be related to #42
Out of curiosity, if you try with Dapper.FluentMap 1.4.1 instead of 1.5.* does it work?
henkmollema commentedon Aug 16, 2016
@Darkwind791 as @cpisto mentiond, would you mind testin this against v1.4.1?
bjth commentedon Aug 19, 2016
Hey @henkmollema, sorry only just got around trying this, @cpisto 4.1 is working correctly. Hope that helps.
henkmollema commentedon Nov 16, 2018
This have been fixed for applications targeting full .NET (e.g. 4.5 or higher) and .NET Core 2.0 and 2.1 in version 1.7.0: NuGet and release notes.
Please re-open or create a new issue if the problem persists.