Find In-Memory table in a given database

Note: In Azure if we use premium database functions we can not downgrade those databases into standard pricing tier. We need to remove premium database features before downgrading to Standard tier.

I had to create multiple database copies to reproduce an issue where I don;t need premium database features. I end up deleting In-Memory tables before downgrading.

FYI: I was able to downgrade from P1 to S0 reduce the cost from 435$ a month to 15$ a month on X number of databases.

In-Memory tables is one of the premium database feature.

--
--
select schema_name(schema_id)+'.'+OBJECT_NAME(mt.object_id) TableName from sys.dm_db_xtp_table_memory_stats mt
join sys.tables st on st.object_id = mt.Object_id 
where mt.object_id > 0
--
Advertisements
This entry was posted in SQL, SQL Query, SQL Server, Uncategorized and tagged , , , , , , , , , . Bookmark the permalink.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s