在SQL中查看文件组中有哪些表

SELECT o.[name], o.[type], i.[name], i.[index_id], 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 f.name = 'primary'

 

posted @ 2015-04-17 16:54  Bireyou  阅读(633)  评论(0编辑  收藏  举报