[dba-SQLServer] Copy a database using Elizabeth's suggestion plus parameters

jwcolby jwcolby at colbyconsulting.com
Thu Mar 27 10:53:53 CDT 2008


Eric, 

You are precisely correct, use each tool for what it does best.  I am trying
to build stored procedures or UDFs to do the heavy lifting and will
eventually tie them in to a .Net FE.  Of course I just execute them directly
for the moment.  It would seem that I now have a tool for copying my
template database to an ordername.

My appreciation to all for your assistance.

John W. Colby
Colby Consulting
www.ColbyConsulting.com 
-----Original Message-----
From: dba-sqlserver-bounces at databaseadvisors.com
[mailto:dba-sqlserver-bounces at databaseadvisors.com] On Behalf Of Eric Barro
Sent: Thursday, March 27, 2008 11:07 AM
To: 'Discussion concerning MS SQL Server'
Subject: Re: [dba-SQLServer] Copy a database using Elizabeth's suggestion
plus parameters

Gustav,

.NET is not the tool to use for backing up and restoring SQL databases.
Granted, you may find solutions out there that do that it won't be optimal.
Besides, the tool is already there for you to use. Just use it.

I would use .NET as a UI to call the sprocs but not everything can be done
using .NET. It's just as bad as when the *priests* insist that SQL is the
end all and be all and that you'll go to HELL if you don't do it the TSQL
way.

Eric

-----Original Message-----
From: dba-sqlserver-bounces at databaseadvisors.com
[mailto:dba-sqlserver-bounces at databaseadvisors.com] On Behalf Of Gustav
Brock
Sent: Thursday, March 27, 2008 6:49 AM
To: dba-sqlserver at databaseadvisors.com
Subject: Re: [dba-SQLServer] Copy a database using Elizabeth's suggestion
plus parameters

Hi John

I think you are trapped by the single/double quote syntax for embedded
strings just like when you build string expressions form strings in VBA.
Look in Robert's code how he used Chr(34) to wrap string.

But your trouble is why I suggested to lift this whole thing out of T-SQL
into VB.Net (from where you control the complete process anyway, right?).

/gustav




More information about the dba-SQLServer mailing list