As title is very clear what this post is about I will not write long description. I have listed definition of FILLFACTOR from BOL here.
FILLFACTOR
Specifies a percentage that indicates how full the Database Engine should make the leaf level of each index page during index creation or alteration. fillfactor must be an integer value from 1 to 100. The default is 0.
T-SQL Script to set Server level FILLFACTOR to 90
EXEC sys.sp_configure 'show advanced options', '1'
RECONFIGURE WITH OVERRIDE
GO
EXEC sys.sp_configure 'fill factor (%)', '90'
GO
RECONFIGURE WITH OVERRIDE
GO
EXEC sys.sp_configure 'show advanced options', '0'
RECONFIGURE WITH OVERRIDE
GO
Reference : Pinal Dave (http://blog.SQLAuthority.com)












Hello Pinal,
I have a table which contains 21155716 rows. currently, it takes more than 45 minutes to retrieve data while adding WITH(NOLOCK) on a table.
I did rebuild and reorganize indexes, and also I have set up fillfactors to 90% on indexes. Is there any other thing, I should look into improve the performance on the table. Please let me know.
Thank you for all your help!
Kena
Hello Kena,
If you are retreiving all records then defragmention of clustered index is enough. For the best use of any index, besides defragmentation it’s statistics should also have updated.
Regards,
Pinal Dave
hello.
is there a way to know what value to set the fill factor ??
is there a way to know how much a table is used using T-SQL ??
Hi Daniela
Just to answer your first question- Yes we can see the value of the current Fill Factor by the following query:
SELECT OBJECT_NAME(object_id) AS ‘Table/View’
,name AS ‘Index Name’
,index_id AS ‘ID of Index’
,fill_factor AS ‘Current Fill Factor’
FROM sys.indexes
From SQL Server 2005 and above you can use DMF- sys.dm_db_index_physical_stats to get all the information about your indexes..
I hope that helps.
Thanks