I've set the size of the tempdb to 100Gb. Every night I'd like to run a job that shrinks all contents of the data and log file and have it grow back or stay at 100gb. The reason for this is that I don't want the DB to grow out everyday. 100gb should be sufficient. The other day I was told to do the following. Can someone confirm and or give any suggestions that would help ease my thoughts. Thanks
USE [tempdb]
GO
DBCC SHRINKFILE (N'tempdev' , 0, TRUNCATEONLY)
GO
DBCC SHRINKFILE (N'templog' , 0, TRUNCATEONLY)
GO
USE [tempdb]
GO
DBCC SHRINKFILE (N'tempdev' , 0, TRUNCATEONLY)
GO
DBCC SHRINKFILE (N'templog' , 0, TRUNCATEONLY)
GO