Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 General SQL Server Forums
 New to SQL Server Administration
 how to add a datafile to a database

Author  Topic 

sunsanvin
Master Smack Fu Yak Hacker

1274 Posts

Posted - 2009-07-02 : 11:12:26
Hi All,
i've a production environment, i've a database with 300GB. only one datafile and one log file is available to this.

now i'd like to add one nore datafile and logfile to this database and that will in a different local drive.

can you suggest me ho;w can i do this with lesser downtime?

thanks in advance

Arnav
Even you learn 1%, Learn it with 100% confidence.

mcrowley
Aged Yak Warrior

771 Posts

Posted - 2009-07-02 : 13:28:55
You can use the ALTER DATABASE command to do this with no downtime. Adding a second log file will not help uyou with performance, as log files are used sequentially. I would only add one, if the disk it is currently on is running out of space.
Go to Top of Page
   

- Advertisement -