Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2008 Forums
 SQL Server Administration (2008)
 tables on filegroup

Author  Topic 

noamg
Posting Yak Master

215 Posts

Posted - 2009-10-06 : 08:51:31
hi,

how to know which tables are on a specific filegroup ?

thanks

Noam Graizer

Kabila
Starting Member

33 Posts

Posted - 2009-10-06 : 09:11:03
SELECT o.[name], f.[name]
FROM sys.indexes i INNER JOIN sys.filegroups f
ON i.data_space_id = f.data_space_id INNER JOIN sys.all_objects o
ON i.[object_id] = o.[object_id]
WHERE o.type='U'
Go to Top of Page
   

- Advertisement -