Reputation: 389
Is it possible for a memory optimized table in SQL server to have part of its data in memory and the rest on disk?
I have a requirement to load the last 3 months' data into memory, and the rest of it isn't really required to be in memory because it will not be queried.
Is there any way to do this with memory optimized tables? If not, is there any alternate way to do this?
Upvotes: 1
Views: 735
Reputation: 4439
Use a view to union an in-memory table with a standard table (a partitioned view). Run a maintenance process to move data from the in-memory table to the standard table as needed.
You can add check-constraints to the standard table to help eliminate it from the query if that data will not be touched.
Upvotes: 2
Reputation: 28890
The database can have few tables on disk and few in memory,but it is not possible to have ,some of table data in disk and some data in memory
I have a requirement to load the last 3 months' data into memory, and the rest of it isn't really required to be in memory because it will not be queried
why not archive the table regularly ,so it retains only three months data and optimize it for In-memory usage..
Upvotes: 0