I have installed dapper.aot to the project here are my using statements


using Microsoft.Data.SqlClient;
using Dapper;
using System.Data;
using System.Data.Common;

//I am simply trying var 
  con = new SqlConnection(_connectionString);
  con.Open();
  var test5 = con.Query<Program>("SELECT Name, Acronym FROM Programs");

I get that there is no definition for query or any of the other dapper query methods off connection. I have the ability to see that there is a dapper "command" object off the connection but cant use normal dapper syntax. I am very new to dapper but this should work, and yes I have the attribute [DapperAot] over my Program model.

I expected to find the query methods off the connection

0

There are 0 best solutions below