Working with In-Memory OLTP in SQL Server can be a powerful tool for improving performance. However, when dealing with a large number of tables, it can be challenging to identify which tables are In-Memory. In this article, we will explore a few methods to easily identify In-Memory tables in SQL Server Management Studio (SSMS).
T-SQL Way
One simple solution is to use a T-SQL query to filter out In-Memory tables. By querying the system table sys.tables
and checking the is_memory_optimized
column, we can retrieve only the In-Memory tables in the selected database. Here is an example:
SELECT * FROM sys.tables
WHERE is_memory_optimized = 1
While this method works, it may not be the most convenient way to visualize In-Memory tables in SSMS.
Using Object Explorer
Another method is to utilize the Object Explorer in SSMS. By right-clicking on the Tables node and selecting “Filter Settings,” we can access additional options for filtering based on In-Memory tables. This provides a more visual way to identify In-Memory tables within the database.
Object Explorer Details
The third and simplest method is to use the Object Explorer Details (F7) in SQL Server 2014 SSMS. By right-clicking on the header and adding the “Memory Optimized” column, we can sort the tables based on this column. This will display True or False values, allowing us to easily identify the In-Memory Optimized tables at the top of the list.
These methods provide simple yet powerful tips for working with In-Memory tables in SQL Server 2014. If you have any other methods for filtering out In-Memory Optimized tables inside SSMS, feel free to share them with us.