I am newbie to Dapper and I Want to use Dapper.Contrib. Is there any method we can use store procedure with Dapper.Contrib methods.
e.g The method of Dapper.Contrib is connection.GetAll<Invoice>().ToList();
. I want to call store procedure in this extension methods.
For stored procedures, use .Query<T>
extension.
var result = cnn.Query<Data>("spGetData", new {Id = 1},
commandType: CommandType.StoredProcedure);
Here is a Link to sql mapper extensions source code.