I want to call a stored procedure in an asp dot net core8 API and get it's result from sql. but as the example shows, the procedure is getting called from a DbSet like Poll and query result is converted to PollEntity:
List<PollEntity> polls =await _dbContext.Polls.FromSql($"SpGetPoll").ToListAsync();
But I don't want to create a Poll DbSet, which then should add a migration and create a table in database.
I want to call procedure, and then getting it's result without creating table for it. because the procedure result is not from only one table like StudentTable as online examples show in other sites.
SqlQuery
Raw SQL queries for unmapped types