-2

I am dealing with e-commerce admin panel. I designed dynamic table that lists customer details for admin panel. User can add new columns to table or remove. The table in admin-panel

So I must fetch data from database dynamically. It must just fetch data in the columns that the user selected. By using Entity-Framework, how does I fetch data dynamically? There are total 47 columns and in different tables. Also, I designed all database operations by using stored-procedures. You know that there are entity classes to execute the procedures in EF. What is the best option to solve this problem?

For example, I create a stored-procedure that execute dynamically, but I can't match with entity class in EF. Thank you.

1 Answers1

0

Simply you can't do it using Entity Framework. Entity Framework have typed models (POCO). You might need a custom solution, may be try a datasource of type IDictionary<string, object> which can be converted to ExpandoObject available in C#. But that also depends if your CMS supports it.

vendettamit
  • 14,315
  • 2
  • 32
  • 54