Click here to monitor SSC
SQLServerCentral is supported by Redgate
 
Log in  ::  Register  ::  Not logged in
 
 
 
        
Home       Members    Calendar    Who's On


Add to briefcase

filegroups and tables. Expand / Collapse
Author
Message
Posted Monday, August 27, 2012 2:13 AM
SSC-Addicted

SSC-AddictedSSC-AddictedSSC-AddictedSSC-AddictedSSC-AddictedSSC-AddictedSSC-AddictedSSC-Addicted

Group: General Forum Members
Last Login: Monday, December 5, 2016 2:41 AM
Points: 444, Visits: 2,158
How can I see which tables belong to a filegroup ?

(A selection which gives me all tables belonging to a single filegroup).

Thanks for your time and attention,
Ben brugman
Post #1350245
Posted Monday, August 27, 2012 2:22 AM


SSC-Forever

SSC-ForeverSSC-ForeverSSC-ForeverSSC-ForeverSSC-ForeverSSC-ForeverSSC-ForeverSSC-ForeverSSC-ForeverSSC-ForeverSSC-ForeverSSC-ForeverSSC-ForeverSSC-ForeverSSC-Forever

Group: General Forum Members
Last Login: Saturday, December 3, 2016 5:18 AM
Points: 45,619, Visits: 44,147
SELECT  OBJECT_NAME(object_id) AS TableName ,
i.name AS IndexName ,
ds.name AS FileGroupName
FROM sys.data_spaces AS ds
INNER JOIN sys.indexes AS i ON ds.data_space_id = i.data_space_id




Gail Shaw
Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability

We walk in the dark places no others will enter
We stand on the bridge and no one may pass

Post #1350250
« Prev Topic | Next Topic »

Add to briefcase

Permissions Expand / Collapse