In Entity Framework 6, we had the option to run a stored procedure that returns a specific model object with code like this:
context.Database.SqlQuery<MyModelClass>("SomeStoredProcedure @p0", param1).ToList();
where MyModelClass represents the result set from the stored procedure.
My question is do we have similar kind of option in Entity Framework Core? So far I've been able to find FromSQL but (I could be wrong) this method expects the dbset name, whereas I want to provide plain model class name (because there could be multiple stored procedures with multiple models)
Any suggestion would be greatly appreciated.
Thanks.