[dba-SQLServer] SQL Server 2005 - Copying a database

jwcolby jwcolby at colbyconsulting.com
Thu Sep 10 07:50:31 CDT 2009


While I am at it, I need to shrink the log file after use.  These databases are rarely used after 
they are created but they generate some pretty hefty log files during creation so I need to just 
automatically shrink them back down.

Thanks,

John W. Colby
www.ColbyConsulting.com


jwcolby wrote:
> I need to programmatically copy a database to a new name (make a copy), and specify where the data 
> file and log file goes.  Can anyone give me help in figuring that out?  I want to write a stored 
> procedure to do this and call that from Access.
> 



More information about the dba-SQLServer mailing list