'How can I create a partitioned table in EF Core?
Let's say I have an object like this:
public class ObjectA
{
public int Id {get;set;}
public DateTime CreatedOn {get;set;}
...etc
}
I want to partition by {CreatedOn} and I need to create the table with EF migration. The DB is MSSql. How do I do this?
Solution 1:[1]
You can not. Well, you can by issuing SQL in a migration, but there is no in build support for partitioned tables in EfCore. Which is, among other things, why many people consider EF Migrations to be kind of a sad joke - they cover a lot of what beginners know, but they fall apart the moment you start actually using even the most basic non beginner functions.
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
Solution | Source |
---|---|
Solution 1 | TomTom |