Default datafile settings not applied - by Robert Klimes

Status : 

  By Design<br /><br />
		The product team believes this item works according to its intended design.<br /><br />
		A more detailed explanation for the resolution of this particular item may have been provided in the comments section.

Sign in
to vote
ID 778069 Comments
Status Closed Workarounds
Type Bug Repros 1
Opened 1/31/2013 10:34:38 AM
Access Restriction Public


The model database settings for Autogrowth/Maxsize for mdf and Initial Size and Autogrowth/Maxsize for LDF  do not get applied to new databases if T-sql is used and you do not specify an initial size or autogrowth.
Sign in to post a comment.
Posted by Ajay [MSFT] on 4/25/2013 at 12:48 PM
Thank you for submitting this feedback. After carefully evaluating all of the bugs in our pipeline, we are closing this bug as a viable workaround is available.
Thanks again for reporting the product issue and continued support in improving our product.

Senior Program Manager
Microsoft Corporation
Posted by Pieter Vanhove on 3/20/2013 at 3:32 AM
According to BOL
The following example creates the database mytest and creates a corresponding primary and transaction log file. Because the statement has no <filespec> items, the primary database file is the size of the model database primary file. The transaction log is set to the larger of these values: 512KB or 25% the size of the primary data file. Because MAXSIZE is not specified, the files can grow to fill all available disk space.
Would be nice to also use the default autogrowth setting.
When you create a database with the GUI of the SQL Server Management Studio, then it's using the default settings of the model DB. When you script it, it's actually using the size option in the T-SQL script.