none
mapping single entity type to dynamically generated tables RRS feed

  • Question

  • Hello,

    I am new to entity framework and have the following requirement - 

    I have a set of tables that are generated dynamically from the application, for example - TableNameX with columns like - IdX, DescriptionX, UpdateNameX, UpdateDateX etc. where X can be 0 to 9. So I can have 0 or upto 10 tables at a given point of time in my application.

    I have do to CRUD operations using my application on these tables.

    How do I use entity framework in this kind of scenario ?

    Is it possible that I create a single POCO and then map it dynamically to the tables during the CRUD operations?

    Thanks, Saurav


    Wednesday, April 9, 2014 11:22 AM

Answers

  • Your solution is not suitable for EF implementation. I suggest that you look into dynamic parameterized T-SQL for CRUD operations. 
    Wednesday, April 9, 2014 10:23 PM