Closed dboretti closed 3 years ago
@dboretti, Hi!
Deserialization (i.e. mapping) doesn't work with private properties. You need to make them public, like this:
public class Companies_Global
{
public string Company_Guid { get; set; }
public string Name { get; set; }
}
Oh what an oversight from my side, sorry for that, now it works perfectly, thanks very much! Very nice project! I count to use it for a very basic REST API instead of the standard .net connector
Hi, I'm using the latest version of the library (0.3.4) with a .net core console app, target framework .NET 5.0 (but I've seen mapping doesn't work also with 3.1) The connection to SnowFlake using the standard constructor works, also the "ExecuteScalarAsync" method works, what is causing problems is "QueryAsync"
"comp" has 3 items (which is correct) but all of them have the properties "Company_Guid" and "Name" always null when I highlight the "comp" item when debugging I see this:
{Snowflake.Client.SnowflakeDataMapper.d__2}
I've tried also to use QueryRawResponseAsync in this way but had the same issue:
in this latest example companies.Columns and companies.Rows are filled correctly by the QueryRawResponseAsync method with all the columns and all the rows data returned by the query