Saturday, February 25, 2012
Move db
I have WIn2003 SP1+SQL2000 SP3.
Al the DB sites on drive D, I installed new HD Edrive.
I need to move all the DB to the new drive.
What is the best to do that?
Than'x
Shayhttp://www.webservertalk.com/archive132-2004-7-330935.html
--
Aaron Bertrand
SQL Server MVP
"S" <s@.s.com> wrote in message news:uF11vLf2HHA.5740@.TK2MSFTNGP04.phx.gbl...
> Hi
> I have WIn2003 SP1+SQL2000 SP3.
> Al the DB sites on drive D, I installed new HD Edrive.
> I need to move all the DB to the new drive.
> What is the best to do that?
> Than'x
> Shay
>|||Search the Books On Line (BOL) for Detach and Attach:
Quoting BOL:
To move a database, or database file, to another server or disk:
1) Detach the database.
2) Move the database file(s) to the other server or disk.
3) Attach the database specifying the new location of the moved
file(s).
My only additional comment is that I would have really good backups
first, and I would COPY rather than MOVE, only getting rid of the
oroginal files after the database is working from the new location.
Roy Harvey
Beacon Falls, CT
On Wed, 8 Aug 2007 22:32:15 +0200, "S" <s@.s.com> wrote:
>Hi
>I have WIn2003 SP1+SQL2000 SP3.
>Al the DB sites on drive D, I installed new HD Edrive.
>I need to move all the DB to the new drive.
>What is the best to do that?
>Than'x
>Shay
>|||On Aug 8, 2:44 pm, Roy Harvey <roy_har...@.snet.net> wrote:
> Search the Books On Line (BOL) for Detach and Attach:
> Quoting BOL:
> To move a database, or database file, to another server or disk:
> 1) Detach the database.
> 2) Move the database file(s) to the other server or disk.
> 3) Attach the database specifying the new location of the moved
> file(s).
> My only additional comment is that I would have really good backups
> first, and I would COPY rather than MOVE, only getting rid of the
> oroginal files after the database is working from the new location.
> Roy Harvey
> Beacon Falls, CT
>
> On Wed, 8 Aug 2007 22:32:15 +0200, "S" <s...@.s.com> wrote:
> >Hi
> >I have WIn2003 SP1+SQL2000 SP3.
> >Al the DB sites on drive D, I installed new HD Edrive.
> >I need to move all the DB to the new drive.
> >What is the best to do that?
> >Than'x
> >Shay- Hide quoted text -
> - Show quoted text -
I agree with the detach and attach method in this case. You should
simply detach the database(s) you wish to move, move the files to
their new location, the simply run the attach method. It will ask you
to browse for your .mdf and .ldf files and voila, you will be done.
move datafiles to SAN
Apparently not .. Sorry
"sivan" <sivan@.discussions.microsoft.com> wrote in message
news:958C0429-77A1-44F8-B38E-F7DED1BC6766@.microsoft.com...
> Is there a way to move data files to SAN without causing downtime to sql
server
|||Hi,
You have to detach the database and then copy the files to SAN drive and then
attach it back. As soon as you detach the database , the database will not
be available till you attach it back.
FYI, ALL the other databases in the same instance will be available during
this time.
Thanks
Hari
MCDBA
"Hassan" wrote:
> Apparently not .. Sorry
> "sivan" <sivan@.discussions.microsoft.com> wrote in message
> news:958C0429-77A1-44F8-B38E-F7DED1BC6766@.microsoft.com...
> server
>
>
|||"Hari Prasad" <HariPrasad@.discussions.microsoft.com> wrote in message
news:BF369363-8765-48E0-9C2C-27857A2312ED@.microsoft.com...
> Hi,
> You have to detach the database and then copy the files to SAN drive and
then
> attach it back. As soon as you detach the database , the database will not
> be available till you attach it back.
>
There's one way that may minimize downtime.
Backup your databases and restore them with a new name (this time located on
the SAN).
Then stop activity to the DB Server, perform a transaction log backup of the
databases, restore those to the new databases, drop the old databases,
rename the new ones and you SHOULD be good to go.
If you script it, your downtime can be measured in minutes.
But I would practice this a LOT.
[vbcol=seagreen]
> FYI, ALL the other databases in the same instance will be available during
> this time.
> Thanks
> Hari
> MCDBA
>
>
> "Hassan" wrote:
sql[vbcol=seagreen]
move datafiles to SAN
"sivan" <sivan@.discussions.microsoft.com> wrote in message
news:958C0429-77A1-44F8-B38E-F7DED1BC6766@.microsoft.com...
> Is there a way to move data files to SAN without causing downtime to sql
server|||Hi,
You have to detach the database and then copy the files to SAN drive and then
attach it back. As soon as you detach the database , the database will not
be available till you attach it back.
FYI, ALL the other databases in the same instance will be available during
this time.
Thanks
Hari
MCDBA
"Hassan" wrote:
> Apparently not .. Sorry
> "sivan" <sivan@.discussions.microsoft.com> wrote in message
> news:958C0429-77A1-44F8-B38E-F7DED1BC6766@.microsoft.com...
> > Is there a way to move data files to SAN without causing downtime to sql
> server
>
>|||"Hari Prasad" <HariPrasad@.discussions.microsoft.com> wrote in message
news:BF369363-8765-48E0-9C2C-27857A2312ED@.microsoft.com...
> Hi,
> You have to detach the database and then copy the files to SAN drive and
then
> attach it back. As soon as you detach the database , the database will not
> be available till you attach it back.
>
There's one way that may minimize downtime.
Backup your databases and restore them with a new name (this time located on
the SAN).
Then stop activity to the DB Server, perform a transaction log backup of the
databases, restore those to the new databases, drop the old databases,
rename the new ones and you SHOULD be good to go.
If you script it, your downtime can be measured in minutes.
But I would practice this a LOT.
> FYI, ALL the other databases in the same instance will be available during
> this time.
> Thanks
> Hari
> MCDBA
>
>
> "Hassan" wrote:
> > Apparently not .. Sorry
> >
> > "sivan" <sivan@.discussions.microsoft.com> wrote in message
> > news:958C0429-77A1-44F8-B38E-F7DED1BC6766@.microsoft.com...
> > > Is there a way to move data files to SAN without causing downtime to
sql
> > server
> >
> >
> >
Move datafile
I need to move some datafiles from E to F. These datafiles are into of the filegroups.
i.e:
Actual
FILEGROUP: CDL_DATA e CDL_IDX
DATAFILE'S: e:\data\Cdl_data.NDF e e:\data\Cdl_idx_data.NDF
Changed
FILEGROUP: CDL_DATA e CDL_IDX
DATAFILE'S: F:\data\Cdl_data.NDF e F:\data\Cdl_idx_data.NDF
Is there a easy way by Enterprise Manager that I can do this job?
Thank you by atentionHi,
You can move datafiles of a DB using Detach & Attach procs..
Search for 'sp_detachdb' eg in BOL.. its straightforward mate..
cheers
ganesh
Move databases to new server
What is the best way to accomplish this?
Thanks,
JeffHi,
The easy way to move the database is ,
1. SP_DETACH_DB DBNAME
2. Move the .mdf and .ldf files to new server
3. SP_ATTACH_DB dbanme,@.filename1='',@.filename2=''
or else you can move a database using below steps,
1. Do a Backup of database
2. Copy the .BAK file to new server
3. Restore the database
4. Delete the database from old server
Thanks
Hari
MCDBA
"Jeff" <jeffpoling@.yahoo.com> wrote in message
news:OV0RlKizDHA.1524@.TK2MSFTNGP10.phx.gbl...
> I need to move databases from one server to another (upgrading equipment).
> What is the best way to accomplish this?
> Thanks,
> Jeff
>
Move databases to a larger drive
SQLServer service was stopped, the physical files were manually copied to
the new larger drives, and the SQLServer service was restarted. The problem
is that now when I go to expand the databases (the entire purpose of the
upgrade) SQL Exec doesn't appear to see the larger drive capacity. The
drive lettering was adjusted such that the new larger drives containing the
databases have the drive letters of the original drives, and SQL Exec sees
the databases and brings them online. Is there some other process I should
have used? Is there a way to get SQL Exec to recognize the empty space on
the new drive? Any and all help is greatly appreciated.
One must ask..
What the hell are you still doing on 6.5!
"Jason Rosenblum" <jrosenblum@.wcmh.org> wrote in message
news:O$i6htcfEHA.4092@.TK2MSFTNGP10.phx.gbl...
> I have a SQL 6.5 server running on WinNTthat was recently upgraded. The
> SQLServer service was stopped, the physical files were manually copied to
> the new larger drives, and the SQLServer service was restarted. The
problem
> is that now when I go to expand the databases (the entire purpose of the
> upgrade) SQL Exec doesn't appear to see the larger drive capacity. The
> drive lettering was adjusted such that the new larger drives containing
the
> databases have the drive letters of the original drives, and SQL Exec sees
> the databases and brings them online. Is there some other process I
should
> have used? Is there a way to get SQL Exec to recognize the empty space on
> the new drive? Any and all help is greatly appreciated.
>
|||Hi,
Have a look into the below link. ( Describes the various methods to load XML
to SQl 2000 tables)
http://www.perfectxml.com/articles/xml/importxmlsql.asp
Thanks
Hari
MCDBA
"Jason Rosenblum" <jrosenblum@.wcmh.org> wrote in message
news:O$i6htcfEHA.4092@.TK2MSFTNGP10.phx.gbl...
> I have a SQL 6.5 server running on WinNTthat was recently upgraded. The
> SQLServer service was stopped, the physical files were manually copied to
> the new larger drives, and the SQLServer service was restarted. The
problem
> is that now when I go to expand the databases (the entire purpose of the
> upgrade) SQL Exec doesn't appear to see the larger drive capacity. The
> drive lettering was adjusted such that the new larger drives containing
the
> databases have the drive letters of the original drives, and SQL Exec sees
> the databases and brings them online. Is there some other process I
should
> have used? Is there a way to get SQL Exec to recognize the empty space on
> the new drive? Any and all help is greatly appreciated.
>
|||Sorry I posted.. wrongly...
Thanks
Hari
"Hari Prasad" <hari_prasad_k@.hotmail.com> wrote in message
news:OfImQ8dfEHA.592@.TK2MSFTNGP11.phx.gbl...
> Hi,
> Have a look into the below link. ( Describes the various methods to load
XML[vbcol=seagreen]
> to SQl 2000 tables)
> http://www.perfectxml.com/articles/xml/importxmlsql.asp
> Thanks
> Hari
> MCDBA
>
> "Jason Rosenblum" <jrosenblum@.wcmh.org> wrote in message
> news:O$i6htcfEHA.4092@.TK2MSFTNGP10.phx.gbl...
to[vbcol=seagreen]
> problem
> the
sees[vbcol=seagreen]
> should
on
>
Move databases to a larger drive
SQLServer service was stopped, the physical files were manually copied to
the new larger drives, and the SQLServer service was restarted. The problem
is that now when I go to expand the databases (the entire purpose of the
upgrade) SQL Exec doesn't appear to see the larger drive capacity. The
drive lettering was adjusted such that the new larger drives containing the
databases have the drive letters of the original drives, and SQL Exec sees
the databases and brings them online. Is there some other process I should
have used? Is there a way to get SQL Exec to recognize the empty space on
the new drive? Any and all help is greatly appreciated.One must ask..
What the hell are you still doing on 6.5!
"Jason Rosenblum" <jrosenblum@.wcmh.org> wrote in message
news:O$i6htcfEHA.4092@.TK2MSFTNGP10.phx.gbl...
> I have a SQL 6.5 server running on WinNTthat was recently upgraded. The
> SQLServer service was stopped, the physical files were manually copied to
> the new larger drives, and the SQLServer service was restarted. The
problem
> is that now when I go to expand the databases (the entire purpose of the
> upgrade) SQL Exec doesn't appear to see the larger drive capacity. The
> drive lettering was adjusted such that the new larger drives containing
the
> databases have the drive letters of the original drives, and SQL Exec sees
> the databases and brings them online. Is there some other process I
should
> have used? Is there a way to get SQL Exec to recognize the empty space on
> the new drive? Any and all help is greatly appreciated.
>|||Hi,
Have a look into the below link. ( Describes the various methods to load XML
to SQl 2000 tables)
http://www.perfectxml.com/articles/xml/importxmlsql.asp
Thanks
Hari
MCDBA
"Jason Rosenblum" <jrosenblum@.wcmh.org> wrote in message
news:O$i6htcfEHA.4092@.TK2MSFTNGP10.phx.gbl...
> I have a SQL 6.5 server running on WinNTthat was recently upgraded. The
> SQLServer service was stopped, the physical files were manually copied to
> the new larger drives, and the SQLServer service was restarted. The
problem
> is that now when I go to expand the databases (the entire purpose of the
> upgrade) SQL Exec doesn't appear to see the larger drive capacity. The
> drive lettering was adjusted such that the new larger drives containing
the
> databases have the drive letters of the original drives, and SQL Exec sees
> the databases and brings them online. Is there some other process I
should
> have used? Is there a way to get SQL Exec to recognize the empty space on
> the new drive? Any and all help is greatly appreciated.
>|||Sorry I posted.. wrongly...
Thanks
Hari
"Hari Prasad" <hari_prasad_k@.hotmail.com> wrote in message
news:OfImQ8dfEHA.592@.TK2MSFTNGP11.phx.gbl...
> Hi,
> Have a look into the below link. ( Describes the various methods to load
XML
> to SQl 2000 tables)
> http://www.perfectxml.com/articles/xml/importxmlsql.asp
> Thanks
> Hari
> MCDBA
>
> "Jason Rosenblum" <jrosenblum@.wcmh.org> wrote in message
> news:O$i6htcfEHA.4092@.TK2MSFTNGP10.phx.gbl...
to[vbcol=seagreen]
> problem
> the
sees[vbcol=seagreen]
> should
on[vbcol=seagreen]
>
Move databases to a larger drive
SQLServer service was stopped, the physical files were manually copied to
the new larger drives, and the SQLServer service was restarted. The problem
is that now when I go to expand the databases (the entire purpose of the
upgrade) SQL Exec doesn't appear to see the larger drive capacity. The
drive lettering was adjusted such that the new larger drives containing the
databases have the drive letters of the original drives, and SQL Exec sees
the databases and brings them online. Is there some other process I should
have used? Is there a way to get SQL Exec to recognize the empty space on
the new drive? Any and all help is greatly appreciated.One must ask..
What the hell are you still doing on 6.5!
"Jason Rosenblum" <jrosenblum@.wcmh.org> wrote in message
news:O$i6htcfEHA.4092@.TK2MSFTNGP10.phx.gbl...
> I have a SQL 6.5 server running on WinNTthat was recently upgraded. The
> SQLServer service was stopped, the physical files were manually copied to
> the new larger drives, and the SQLServer service was restarted. The
problem
> is that now when I go to expand the databases (the entire purpose of the
> upgrade) SQL Exec doesn't appear to see the larger drive capacity. The
> drive lettering was adjusted such that the new larger drives containing
the
> databases have the drive letters of the original drives, and SQL Exec sees
> the databases and brings them online. Is there some other process I
should
> have used? Is there a way to get SQL Exec to recognize the empty space on
> the new drive? Any and all help is greatly appreciated.
>|||Hi,
Have a look into the below link. ( Describes the various methods to load XML
to SQl 2000 tables)
http://www.perfectxml.com/articles/xml/importxmlsql.asp
Thanks
Hari
MCDBA
"Jason Rosenblum" <jrosenblum@.wcmh.org> wrote in message
news:O$i6htcfEHA.4092@.TK2MSFTNGP10.phx.gbl...
> I have a SQL 6.5 server running on WinNTthat was recently upgraded. The
> SQLServer service was stopped, the physical files were manually copied to
> the new larger drives, and the SQLServer service was restarted. The
problem
> is that now when I go to expand the databases (the entire purpose of the
> upgrade) SQL Exec doesn't appear to see the larger drive capacity. The
> drive lettering was adjusted such that the new larger drives containing
the
> databases have the drive letters of the original drives, and SQL Exec sees
> the databases and brings them online. Is there some other process I
should
> have used? Is there a way to get SQL Exec to recognize the empty space on
> the new drive? Any and all help is greatly appreciated.
>|||Sorry I posted.. wrongly...
Thanks
Hari
"Hari Prasad" <hari_prasad_k@.hotmail.com> wrote in message
news:OfImQ8dfEHA.592@.TK2MSFTNGP11.phx.gbl...
> Hi,
> Have a look into the below link. ( Describes the various methods to load
XML
> to SQl 2000 tables)
> http://www.perfectxml.com/articles/xml/importxmlsql.asp
> Thanks
> Hari
> MCDBA
>
> "Jason Rosenblum" <jrosenblum@.wcmh.org> wrote in message
> news:O$i6htcfEHA.4092@.TK2MSFTNGP10.phx.gbl...
> > I have a SQL 6.5 server running on WinNTthat was recently upgraded. The
> > SQLServer service was stopped, the physical files were manually copied
to
> > the new larger drives, and the SQLServer service was restarted. The
> problem
> > is that now when I go to expand the databases (the entire purpose of the
> > upgrade) SQL Exec doesn't appear to see the larger drive capacity. The
> > drive lettering was adjusted such that the new larger drives containing
> the
> > databases have the drive letters of the original drives, and SQL Exec
sees
> > the databases and brings them online. Is there some other process I
> should
> > have used? Is there a way to get SQL Exec to recognize the empty space
on
> > the new drive? Any and all help is greatly appreciated.
> >
> >
>
Move databases to a different drive
drive is getting full.
We have added a 200MB drive that we are going to use for Data and want
to move our data only to that drive. We want to leave the program files
on the C: drive and move the data to our D: drive.
How best would we do this. I know we can't just move the data folder.
Thanks,
Tom.Hi,
There are 2 options to you:-
a. Keep the system databases in same drive and move the user databases (both
LDF and MDF) to new drive
b. Move all the system and user databases (MDF and LDF) to new drive
a.
1. Use the procedure SP_DETACH_DB <dbname> to detach the databases
2. Create a new folder in new drive and copy the MDF and LDF to new folder
3. Use sp_attach_db
'dbname','driveletter\folder\dbname.mdf','driveletter\folder\dbname.ldf'
I feel that since you have added only 200 MB to new drive it is safe to keep
the System databases in C drive itself.
If you need to mave then then have a look into the below article to move all
databases:-
http://support.microsoft.com/default.aspx?scid=kb;EN-US;224071
Thanks
Hari
MCDBA
"Thomas Scheiderich" <tfs@.deltanet.com> wrote in message
news:408F1C0D.800@.deltanet.com...
> I am looking at moving our databases to a different drive as our C:
> drive is getting full.
> We have added a 200MB drive that we are going to use for Data and want
> to move our data only to that drive. We want to leave the program files
> on the C: drive and move the data to our D: drive.
> How best would we do this. I know we can't just move the data folder.
> Thanks,
> Tom.
>|||Detach and Attach is probably the best bet.
"Thomas Scheiderich" <tfs@.deltanet.com> wrote in message
news:408F1C0D.800@.deltanet.com...
> I am looking at moving our databases to a different drive as our C:
> drive is getting full.
> We have added a 200MB drive that we are going to use for Data and want
> to move our data only to that drive. We want to leave the program files
> on the C: drive and move the data to our D: drive.
> How best would we do this. I know we can't just move the data folder.
> Thanks,
> Tom.
>|||For user databases, yes, I would recommend the same thing. Unfortunately,
that won't move master/model/msdb/tempdb, nor will it make the new location
the default for newly-created databases.
The cleanest way would probably be to do this:
(a) detach your user databases
(b) reinstall SQL Server and all SPs/patches, customizing the data folder
location
(c) move the detached MDF files to the new data location
(d) re-attach
If you can't afford downtime, then the safest thing to do would be to leave
the system databases where they are, and re-attach the user databases from
the new location.
--
Aaron Bertrand
SQL Server MVP
http://www.aspfaq.com/
"Don Peterson" <no1@.nunya.com> wrote in message
news:OagiiANLEHA.2388@.TK2MSFTNGP09.phx.gbl...
> Detach and Attach is probably the best bet.|||Aaron Bertrand [MVP] wrote:
> For user databases, yes, I would recommend the same thing. Unfortunately,
> that won't move master/model/msdb/tempdb, nor will it make the new location
> the default for newly-created databases.
Can't I use the same detach/attach procedures for these databases, also?
Do I have to have my Server programs on the data drive to get it to be
the default location for newly-created databases?
I was thinking it would be good to have the data on a different drive
than my program files.
> The cleanest way would probably be to do this:
> (a) detach your user databases
> (b) reinstall SQL Server and all SPs/patches, customizing the data folder
> location
How do I customise the data folder location and why can't I do that with
the old install?
> (c) move the detached MDF files to the new data location
> (d) re-attach
> If you can't afford downtime, then the safest thing to do would be to leave
> the system databases where they are, and re-attach the user databases from
> the new location.
>|||> Can't I use the same detach/attach procedures for these databases, also?
No, you can't just detach master, tempdb, etc.
> How do I customise the data folder location and why can't I do that with
> the old install?
You can do this during setup. I've never tried to change the default once
SQL Server has been installed; it's likely to be a painful exercise.
--
Aaron Bertrand
SQL Server MVP
http://www.aspfaq.com/|||Check out the following article for detailed instructions on how to move the
system databases:
http://support.microsoft.com/default.aspx?scid=kb;en-us;224071&Product=sql2k
As for changing the default location for databases, that is easy. In
Enterprise Manager, right click on the server and open properties, on the
Database Settings tab down near the bottom you can specify a default
location for new databases.
"Aaron Bertrand - MVP" <aaron@.TRASHaspfaq.com> wrote in message
news:OE2qXdWLEHA.620@.TK2MSFTNGP10.phx.gbl...
> > Can't I use the same detach/attach procedures for these databases, also?
> No, you can't just detach master, tempdb, etc.
> > How do I customise the data folder location and why can't I do that with
> > the old install?
> You can do this during setup. I've never tried to change the default once
> SQL Server has been installed; it's likely to be a painful exercise.
> --
> Aaron Bertrand
> SQL Server MVP
> http://www.aspfaq.com/
>
Move databases to a different drive
drive is getting full.
We have added a 200MB drive that we are going to use for Data and want
to move our data only to that drive. We want to leave the program files
on the C: drive and move the data to our D: drive.
How best would we do this. I know we can't just move the data folder.
Thanks,
Tom.
Hi,
There are 2 options to you:-
a. Keep the system databases in same drive and move the user databases (both
LDF and MDF) to new drive
b. Move all the system and user databases (MDF and LDF) to new drive
a.
1. Use the procedure SP_DETACH_DB <dbname> to detach the databases
2. Create a new folder in new drive and copy the MDF and LDF to new folder
3. Use sp_attach_db
'dbname','driveletter\folder\dbname.mdf','drivelet ter\folder\dbname.ldf'
I feel that since you have added only 200 MB to new drive it is safe to keep
the System databases in C drive itself.
If you need to mave then then have a look into the below article to move all
databases:-
http://support.microsoft.com/default...b;EN-US;224071
Thanks
Hari
MCDBA
"Thomas Scheiderich" <tfs@.deltanet.com> wrote in message
news:408F1C0D.800@.deltanet.com...
> I am looking at moving our databases to a different drive as our C:
> drive is getting full.
> We have added a 200MB drive that we are going to use for Data and want
> to move our data only to that drive. We want to leave the program files
> on the C: drive and move the data to our D: drive.
> How best would we do this. I know we can't just move the data folder.
> Thanks,
> Tom.
>
|||Detach and Attach is probably the best bet.
"Thomas Scheiderich" <tfs@.deltanet.com> wrote in message
news:408F1C0D.800@.deltanet.com...
> I am looking at moving our databases to a different drive as our C:
> drive is getting full.
> We have added a 200MB drive that we are going to use for Data and want
> to move our data only to that drive. We want to leave the program files
> on the C: drive and move the data to our D: drive.
> How best would we do this. I know we can't just move the data folder.
> Thanks,
> Tom.
>
|||For user databases, yes, I would recommend the same thing. Unfortunately,
that won't move master/model/msdb/tempdb, nor will it make the new location
the default for newly-created databases.
The cleanest way would probably be to do this:
(a) detach your user databases
(b) reinstall SQL Server and all SPs/patches, customizing the data folder
location
(c) move the detached MDF files to the new data location
(d) re-attach
If you can't afford downtime, then the safest thing to do would be to leave
the system databases where they are, and re-attach the user databases from
the new location.
Aaron Bertrand
SQL Server MVP
http://www.aspfaq.com/
"Don Peterson" <no1@.nunya.com> wrote in message
news:OagiiANLEHA.2388@.TK2MSFTNGP09.phx.gbl...
> Detach and Attach is probably the best bet.
|||Aaron Bertrand [MVP] wrote:
> For user databases, yes, I would recommend the same thing. Unfortunately,
> that won't move master/model/msdb/tempdb, nor will it make the new location
> the default for newly-created databases.
Can't I use the same detach/attach procedures for these databases, also?
Do I have to have my Server programs on the data drive to get it to be
the default location for newly-created databases?
I was thinking it would be good to have the data on a different drive
than my program files.
> The cleanest way would probably be to do this:
> (a) detach your user databases
> (b) reinstall SQL Server and all SPs/patches, customizing the data folder
> location
How do I customise the data folder location and why can't I do that with
the old install?
> (c) move the detached MDF files to the new data location
> (d) re-attach
> If you can't afford downtime, then the safest thing to do would be to leave
> the system databases where they are, and re-attach the user databases from
> the new location.
>
|||> Can't I use the same detach/attach procedures for these databases, also?
No, you can't just detach master, tempdb, etc.
> How do I customise the data folder location and why can't I do that with
> the old install?
You can do this during setup. I've never tried to change the default once
SQL Server has been installed; it's likely to be a painful exercise.
Aaron Bertrand
SQL Server MVP
http://www.aspfaq.com/
|||Check out the following article for detailed instructions on how to move the
system databases:
http://support.microsoft.com/default...&Product=sql2k
As for changing the default location for databases, that is easy. In
Enterprise Manager, right click on the server and open properties, on the
Database Settings tab down near the bottom you can specify a default
location for new databases.
"Aaron Bertrand - MVP" <aaron@.TRASHaspfaq.com> wrote in message
news:OE2qXdWLEHA.620@.TK2MSFTNGP10.phx.gbl...
> No, you can't just detach master, tempdb, etc.
>
> You can do this during setup. I've never tried to change the default once
> SQL Server has been installed; it's likely to be a painful exercise.
> --
> Aaron Bertrand
> SQL Server MVP
> http://www.aspfaq.com/
>
Move databases to a different drive
drive is getting full.
We have added a 200MB drive that we are going to use for Data and want
to move our data only to that drive. We want to leave the program files
on the C: drive and move the data to our D: drive.
How best would we do this. I know we can't just move the data folder.
Thanks,
Tom.Hi,
There are 2 options to you:-
a. Keep the system databases in same drive and move the user databases (both
LDF and MDF) to new drive
b. Move all the system and user databases (MDF and LDF) to new drive
a.
1. Use the procedure SP_DETACH_DB <dbname> to detach the databases
2. Create a new folder in new drive and copy the MDF and LDF to new folder
3. Use sp_attach_db
'dbname','driveletter\folder\dbname.mdf','driveletter\folder\dbname.ldf'
I feel that since you have added only 200 MB to new drive it is safe to keep
the System databases in C drive itself.
If you need to mave then then have a look into the below article to move all
databases:-
http://support.microsoft.com/defaul...kb;EN-US;224071
Thanks
Hari
MCDBA
"Thomas Scheiderich" <tfs@.deltanet.com> wrote in message
news:408F1C0D.800@.deltanet.com...
> I am looking at moving our databases to a different drive as our C:
> drive is getting full.
> We have added a 200MB drive that we are going to use for Data and want
> to move our data only to that drive. We want to leave the program files
> on the C: drive and move the data to our D: drive.
> How best would we do this. I know we can't just move the data folder.
> Thanks,
> Tom.
>|||Detach and Attach is probably the best bet.
"Thomas Scheiderich" <tfs@.deltanet.com> wrote in message
news:408F1C0D.800@.deltanet.com...
> I am looking at moving our databases to a different drive as our C:
> drive is getting full.
> We have added a 200MB drive that we are going to use for Data and want
> to move our data only to that drive. We want to leave the program files
> on the C: drive and move the data to our D: drive.
> How best would we do this. I know we can't just move the data folder.
> Thanks,
> Tom.
>|||For user databases, yes, I would recommend the same thing. Unfortunately,
that won't move master/model/msdb/tempdb, nor will it make the new location
the default for newly-created databases.
The cleanest way would probably be to do this:
(a) detach your user databases
(b) reinstall SQL Server and all SPs/patches, customizing the data folder
location
(c) move the detached MDF files to the new data location
(d) re-attach
If you can't afford downtime, then the safest thing to do would be to leave
the system databases where they are, and re-attach the user databases from
the new location.
Aaron Bertrand
SQL Server MVP
http://www.aspfaq.com/
"Don Peterson" <no1@.nunya.com> wrote in message
news:OagiiANLEHA.2388@.TK2MSFTNGP09.phx.gbl...
> Detach and Attach is probably the best bet.|||Aaron Bertrand [MVP] wrote:
> For user databases, yes, I would recommend the same thing. Unfortunately,
> that won't move master/model/msdb/tempdb, nor will it make the new locatio
n
> the default for newly-created databases.
Can't I use the same detach/attach procedures for these databases, also?
Do I have to have my Server programs on the data drive to get it to be
the default location for newly-created databases?
I was thinking it would be good to have the data on a different drive
than my program files.
> The cleanest way would probably be to do this:
> (a) detach your user databases
> (b) reinstall SQL Server and all SPs/patches, customizing the data folder
> location
How do I customise the data folder location and why can't I do that with
the old install?
> (c) move the detached MDF files to the new data location
> (d) re-attach
> If you can't afford downtime, then the safest thing to do would be to leav
e
> the system databases where they are, and re-attach the user databases from
> the new location.
>|||> Can't I use the same detach/attach procedures for these databases, also?
No, you can't just detach master, tempdb, etc.
> How do I customise the data folder location and why can't I do that with
> the old install?
You can do this during setup. I've never tried to change the default once
SQL Server has been installed; it's likely to be a painful exercise.
Aaron Bertrand
SQL Server MVP
http://www.aspfaq.com/|||Check out the following article for detailed instructions on how to move the
system databases:
http://support.microsoft.com/defaul...1&Product=sql2k
As for changing the default location for databases, that is easy. In
Enterprise Manager, right click on the server and open properties, on the
Database Settings tab down near the bottom you can specify a default
location for new databases.
"Aaron Bertrand - MVP" <aaron@.TRASHaspfaq.com> wrote in message
news:OE2qXdWLEHA.620@.TK2MSFTNGP10.phx.gbl...
> No, you can't just detach master, tempdb, etc.
>
> You can do this during setup. I've never tried to change the default once
> SQL Server has been installed; it's likely to be a painful exercise.
> --
> Aaron Bertrand
> SQL Server MVP
> http://www.aspfaq.com/
>
Move Databases on SQL 2000 Machines
Both machines are running SQL2K. I'd like to place the production database
in a directory on the destination machine with a slightly different path
name than the source SQL server.
How can I shrink the transaction log to the minimum size before I try the
move? What is the best way to move the database to the new machine? We
have Veritus Backup Exec.
Regards,
Charles MacLeanPut the database offline, copy the data file/s and the transaction log/s,
and attach the database file from the new path (sp_attach_db).
You can use the command for attaching a single data file recreating a very
small transaction log (sp_attach_single_file_db).
http://support.microsoft.com/kb/224071/EN-US/
Bye
Massimo
"Charles MacLean" <charlesmaclean@.sbcglobal.netha scritto nel messaggio
news:4zAFg.11171$9T3.4998@.newssvr25.news.prodigy.n et...
Quote:
Originally Posted by
I need to move our production database to a brand new machine on our LAN.
Both machines are running SQL2K. I'd like to place the production
database
Quote:
Originally Posted by
in a directory on the destination machine with a slightly different path
name than the source SQL server.
How can I shrink the transaction log to the minimum size before I try the
move? What is the best way to move the database to the new machine? We
have Veritus Backup Exec.
>
Regards,
Charles MacLean
>
>
>
Move databases between local drives ?
the same computer that is running sql server?Backup the database, do a test restore.
Either
detach the database (sp_detach_db)
move the files
attach the database (sp_attach_db)
or
drop the database
restore from backup with move.|||Oops - duplicate post.
move databases
I like to move sql 2000 databases from 2003 server A, on drive D to 2003
server B on drive N. But master database would stop working after I moved to
server B, on drive N.
What I need to do to resolve the problem or is this do able?
Thanks
Check out:
http://support.microsoft.com/default.aspx/kb/224071
Tom
Thomas A. Moreau, BSc, PhD, MCSE, MCDBA
SQL Server MVP
Columnist, SQL Server Professional
Toronto, ON Canada
www.pinpub.com
..
"anoni" <anoni@.discussions.microsoft.com> wrote in message
news:0B68D43F-A774-46F1-BE55-3D78D87D63FD@.microsoft.com...
Hi,
I like to move sql 2000 databases from 2003 server A, on drive D to 2003
server B on drive N. But master database would stop working after I moved to
server B, on drive N.
What I need to do to resolve the problem or is this do able?
Thanks
move databases
I like to move sql 2000 databases from 2003 server A, on drive D to 2003
server B on drive N. But master database would stop working after I moved to
server B, on drive N.
What I need to do to resolve the problem or is this do able?
ThanksCheck out:
http://support.microsoft.com/default.aspx/kb/224071
Tom
----
Thomas A. Moreau, BSc, PhD, MCSE, MCDBA
SQL Server MVP
Columnist, SQL Server Professional
Toronto, ON Canada
www.pinpub.com
.
"anoni" <anoni@.discussions.microsoft.com> wrote in message
news:0B68D43F-A774-46F1-BE55-3D78D87D63FD@.microsoft.com...
Hi,
I like to move sql 2000 databases from 2003 server A, on drive D to 2003
server B on drive N. But master database would stop working after I moved to
server B, on drive N.
What I need to do to resolve the problem or is this do able?
Thanks
move databases
I like to move sql 2000 databases from 2003 server A, on drive D to 2003
server B on drive N. But master database would stop working after I moved to
server B, on drive N.
What I need to do to resolve the problem or is this do able?
ThanksCheck out:
http://support.microsoft.com/default.aspx/kb/224071
--
Tom
----
Thomas A. Moreau, BSc, PhD, MCSE, MCDBA
SQL Server MVP
Columnist, SQL Server Professional
Toronto, ON Canada
www.pinpub.com
.
"anoni" <anoni@.discussions.microsoft.com> wrote in message
news:0B68D43F-A774-46F1-BE55-3D78D87D63FD@.microsoft.com...
Hi,
I like to move sql 2000 databases from 2003 server A, on drive D to 2003
server B on drive N. But master database would stop working after I moved to
server B, on drive N.
What I need to do to resolve the problem or is this do able?
Thanks
Move Database to new Server
best route for this. I am pretty new to this and don't want to mess it up.
Thanks in advance,
Gregdid you hear "=?Utf-8?B?R3JlZw==?=" <Greg@.discussions.microsoft.com> say
in news:0075FE80-A7CD-4D42-8974-EEB3C5CAC806@.microsoft.com:
> I would like to move a database to a different server. What would be
> the best route for this. I am pretty new to this and don't want to
> mess it up.
> Thanks in advance,
> Greg
>
try looking in BOL for the copy database wizard. It's pretty good at
"hand holding" and so long as no on is in teh database when you do it,
works very cleanly. (tools -> wizards -> management -> copy database
wizard)
--
Neil MacMurchy
http://spaces.msn.com/members/neilmacmurchy
http://spaces.msn.com/members/mctblogs|||Hi,
2 approaches:-
I.
1. SP_DETACH_DB DBNAME
2. Move the .mdf and .ldf files to new server
3. SP_ATTACH_DB dbanme,@.filename1='',@.filename2=''
or else you can move a database using below steps,
II.
1. Do a Backup of database
2. Copy the .BAK file to new server
3. Restore the database
see below link for more details:-
http://support.microsoft.com/default.aspx?scid=kb;en-us;314546
Thanks
Hari
SQL Server MVP
"Greg" <Greg@.discussions.microsoft.com> wrote in message
news:0075FE80-A7CD-4D42-8974-EEB3C5CAC806@.microsoft.com...
>I would like to move a database to a different server. What would be the
> best route for this. I am pretty new to this and don't want to mess it
> up.
> Thanks in advance,
> Greg
>
Move Database to new Server
best route for this. I am pretty new to this and don't want to mess it up.
Thanks in advance,
Greg
did you hear "=?Utf-8?B?R3JlZw==?=" <Greg@.discussions.microsoft.com> say
in news:0075FE80-A7CD-4D42-8974-EEB3C5CAC806@.microsoft.com:
> I would like to move a database to a different server. What would be
> the best route for this. I am pretty new to this and don't want to
> mess it up.
> Thanks in advance,
> Greg
>
try looking in BOL for the copy database wizard. It's pretty good at
"hand holding" and so long as no on is in teh database when you do it,
works very cleanly. (tools -> wizards -> management -> copy database
wizard)
Neil MacMurchy
http://spaces.msn.com/members/neilmacmurchy
http://spaces.msn.com/members/mctblogs
|||Hi,
2 approaches:-
I.
1. SP_DETACH_DB DBNAME
2. Move the .mdf and .ldf files to new server
3. SP_ATTACH_DB dbanme,@.filename1='',@.filenameX2=''
or else you can move a database using below steps,
II.
1. Do a Backup of database
2. Copy the .BAK file to new server
3. Restore the database
see below link for more details:-
http://support.microsoft.com/default...b;en-us;314546
Thanks
Hari
SQL Server MVP
"Greg" <Greg@.discussions.microsoft.com> wrote in message
news:0075FE80-A7CD-4D42-8974-EEB3C5CAC806@.microsoft.com...
>I would like to move a database to a different server. What would be the
> best route for this. I am pretty new to this and don't want to mess it
> up.
> Thanks in advance,
> Greg
>
Move Database to new Server
best route for this. I am pretty new to this and don't want to mess it up.
Thanks in advance,
Gregdid you hear "examnotes" <Greg@.discussions.microsoft.com> say
in news:0075FE80-A7CD-4D42-8974-EEB3C5CAC806@.microsoft.com:
> I would like to move a database to a different server. What would be
> the best route for this. I am pretty new to this and don't want to
> mess it up.
> Thanks in advance,
> Greg
>
try looking in BOL for the copy database wizard. It's pretty good at
"hand holding" and so long as no on is in teh database when you do it,
works very cleanly. (tools -> wizards -> management -> copy database
wizard)
Neil MacMurchy
http://spaces.msn.com/members/neilmacmurchy
http://spaces.msn.com/members/mctblogs|||Hi,
2 approaches:-
I.
1. SP_DETACH_DB DBNAME
2. Move the .mdf and .ldf files to new server
3. SP_ATTACH_DB dbanme,@.filename1='',@.filename_2=''
or else you can move a database using below steps,
II.
1. Do a Backup of database
2. Copy the .BAK file to new server
3. Restore the database
see below link for more details:-
http://support.microsoft.com/defaul...kb;en-us;314546
Thanks
Hari
SQL Server MVP
"Greg" <Greg@.discussions.microsoft.com> wrote in message
news:0075FE80-A7CD-4D42-8974-EEB3C5CAC806@.microsoft.com...
>I would like to move a database to a different server. What would be the
> best route for this. I am pretty new to this and don't want to mess it
> up.
> Thanks in advance,
> Greg
>
Move database to new drive w/ same drive letter
I want to move several database files from a small drive to a new one and replace the existing (small) drive with the bigger one.
The drive letter would not change.
Can I just go ahead and boot the server w/o the SQL service running, copy the folders to the new drive, pull out the old drive and replace it with the new one or do I have to go through the whole attach/detach schema as described in http://support.microso
ft.com/default.aspx?scid=KB;EN-US;q224071&ID=KB;EN-US;q224071 ?
Thanks!
Andreas
You don't have to detach/attach... As long as the drive letter and path is
the same, there shouldn't be any problems as long as SQL is shutdown
cleanly.
"Andi" <anonymous@.discussions.microsoft.com> wrote in message
news:A3410D22-0CFC-469E-8BC0-515D3B1A83AF@.microsoft.com...
> Hi all,
> I want to move several database files from a small drive to a new one and
replace the existing (small) drive with the bigger one.
> The drive letter would not change.
> Can I just go ahead and boot the server w/o the SQL service running, copy
the folders to the new drive, pull out the old drive and replace it with the
new one or do I have to go through the whole attach/detach schema as
described in
http://support.microsoft.com/default...;EN-US;q224071 ?
> Thanks!
> Andreas
Move database to new drive w/ same drive letter
I want to move several database files from a small drive to a new one and re
place the existing (small) drive with the bigger one.
The drive letter would not change.
Can I just go ahead and boot the server w/o the SQL service running, copy the folders t
o the new drive, pull out the old drive and replace it with the new one or do I have to
go through the whole attach/detach schema as described in [url]http://support.microso[
/url]
ft.com/default.aspx?scid=KB;EN-US;q224071&ID=KB;EN-US;q224071 ?
Thanks!
AndreasYou don't have to detach/attach... As long as the drive letter and path is
the same, there shouldn't be any problems as long as SQL is shutdown
cleanly.
"Andi" <anonymous@.discussions.microsoft.com> wrote in message
news:A3410D22-0CFC-469E-8BC0-515D3B1A83AF@.microsoft.com...
> Hi all,
> I want to move several database files from a small drive to a new one and
replace the existing (small) drive with the bigger one.
> The drive letter would not change.
> Can I just go ahead and boot the server w/o the SQL service running, copy
the folders to the new drive, pull out the old drive and replace it with the
new one or do I have to go through the whole attach/detach schema as
described in
http://support.microsoft.com/defaul...B;EN-US;q224071 ?seagreen">
> Thanks!
> Andreas
Move database to new drive w/ same drive letter
I want to move several database files from a small drive to a new one and replace the existing (small) drive with the bigger one
The drive letter would not change
Can I just go ahead and boot the server w/o the SQL service running, copy the folders to the new drive, pull out the old drive and replace it with the new one or do I have to go through the whole attach/detach schema as described in http://support.microsoft.com/default.aspx?scid=KB;EN-US;q224071&ID=KB;EN-US;q224071
Thanks
AndreasYou don't have to detach/attach... As long as the drive letter and path is
the same, there shouldn't be any problems as long as SQL is shutdown
cleanly.
"Andi" <anonymous@.discussions.microsoft.com> wrote in message
news:A3410D22-0CFC-469E-8BC0-515D3B1A83AF@.microsoft.com...
> Hi all,
> I want to move several database files from a small drive to a new one and
replace the existing (small) drive with the bigger one.
> The drive letter would not change.
> Can I just go ahead and boot the server w/o the SQL service running, copy
the folders to the new drive, pull out the old drive and replace it with the
new one or do I have to go through the whole attach/detach schema as
described in
http://support.microsoft.com/default.aspx?scid=KB;EN-US;q224071&ID=KB;EN-US;q224071 ?
> Thanks!
> Andreas
Move Database to client
We have a database that we built for a client and we would like to make a
backup of the database and restore the database on our clients Sql Server
box. Both environments are running SQL Server 2000 SP3a.
We make a backup of the database on our server and when we go to the clients
site and run the restore it complains and gives an error message that states
SQL-DMO (ODBC SQLState: 42000) and states we should use the WITH MOVE. We
tried the WITH MOVE but aree not experienced DBA so we are not sure if we
configured it right.
RESTORE DATABASE TEST FROM DISK='C:\TEMP\CDR-Prod.BAK'
WITH MOVE 'TEST_Data' TO 'c:\program files\microsoft sql
server\mssql\data\CDR-Prod_Data.MDF',
MOVE 'TEST_Log' TO ' c:\program files\microsoft sql
server\mssql\data\CDR-Prod_Log.LDF'
We were able to restore the database some how and then it gives us an
SQL-DMO error 21776.
Any ideas on how we should best approach this situation so that we can get
the full database (structure and data)?
Thanks for the assistance.Please post the entire error message. Error 21776 is the
generic error used for an object not found in a collection.
The specifics of what object in what collection would be in
the entire error message.
-Sue
On Sun, 13 Mar 2005 18:55:02 -0800, "Rod S" <Rod
S@.discussions.microsoft.com> wrote:
>Hi,
>We have a database that we built for a client and we would like to make a
>backup of the database and restore the database on our clients Sql Server
>box. Both environments are running SQL Server 2000 SP3a.
>We make a backup of the database on our server and when we go to the clients
>site and run the restore it complains and gives an error message that states
>SQL-DMO (ODBC SQLState: 42000) and states we should use the WITH MOVE. We
>tried the WITH MOVE but aree not experienced DBA so we are not sure if we
>configured it right.
>RESTORE DATABASE TEST FROM DISK='C:\TEMP\CDR-Prod.BAK'
>WITH MOVE 'TEST_Data' TO 'c:\program files\microsoft sql
>server\mssql\data\CDR-Prod_Data.MDF',
>MOVE 'TEST_Log' TO ' c:\program files\microsoft sql
>server\mssql\data\CDR-Prod_Log.LDF'
>
>We were able to restore the database some how and then it gives us an
>SQL-DMO error 21776.
>Any ideas on how we should best approach this situation so that we can get
>the full database (structure and data)?
>Thanks for the assistance.|||Hi,
Sorry Sue, I should have elaborated more:
We have two problems:
1. we areunable to restore the database properly using either the GUI based
restore tool in the Enterprise Manager or usign the Query Analyzer with the
script included.
2. We some how managed to restore the database on the client's server and
when we try to access any component of the "restored" database, we receive
the SQL-DMO 21776 error. Which states the following
"Error 21776: [SQL-DMO} The name 'CDR-Prod' was not found in the Databases
colelction. If the name is a qualified name, use [ ] to separate various
parts of the name and try again."
So what i am looking for is what is the best mechanism to move our database
from out SQL Server 2000 environment to the clients SQL Server 2000
environment where we can preserve the table structure and data contained
within the database.
As well, how can we delete the database that we were able to create but now
is not recognized by the Enterprise manager due to the 21776 error.
I hope this provides a more detailed explanation of the situation we are
facing.
Thanks for the assistance,
Rod
"Sue Hoegemeier" wrote:
> Please post the entire error message. Error 21776 is the
> generic error used for an object not found in a collection.
> The specifics of what object in what collection would be in
> the entire error message.
> -Sue
> On Sun, 13 Mar 2005 18:55:02 -0800, "Rod S" <Rod
> S@.discussions.microsoft.com> wrote:
> >Hi,
> >
> >We have a database that we built for a client and we would like to make a
> >backup of the database and restore the database on our clients Sql Server
> >box. Both environments are running SQL Server 2000 SP3a.
> >
> >We make a backup of the database on our server and when we go to the clients
> >site and run the restore it complains and gives an error message that states
> >SQL-DMO (ODBC SQLState: 42000) and states we should use the WITH MOVE. We
> >tried the WITH MOVE but aree not experienced DBA so we are not sure if we
> >configured it right.
> >
> >RESTORE DATABASE TEST FROM DISK='C:\TEMP\CDR-Prod.BAK'
> >WITH MOVE 'TEST_Data' TO 'c:\program files\microsoft sql
> >server\mssql\data\CDR-Prod_Data.MDF',
> >MOVE 'TEST_Log' TO ' c:\program files\microsoft sql
> >server\mssql\data\CDR-Prod_Log.LDF'
> >
> >
> >We were able to restore the database some how and then it gives us an
> >SQL-DMO error 21776.
> >
> >Any ideas on how we should best approach this situation so that we can get
> >the full database (structure and data)?
> >
> >Thanks for the assistance.
>|||The best mechanism is a backup and restore. You can also use
sp_detach_db, copy the data and log files and have the
client attach the files with sp_attach_db.
I would guess many of the problems are from having a
non-standard database name. The rules for identifier and
what characters are allowed in what positions is in the
books online topic: Using Identifiers
In terms of how to delete the database now, try dropping the
database using query analyzer and putting brackets around
the database name.
drop database [CDR-Prod]
-Sue
On Mon, 14 Mar 2005 08:11:05 -0800, "Rod S"
<RodS@.discussions.microsoft.com> wrote:
>Hi,
>Sorry Sue, I should have elaborated more:
>We have two problems:
>1. we areunable to restore the database properly using either the GUI based
>restore tool in the Enterprise Manager or usign the Query Analyzer with the
>script included.
>2. We some how managed to restore the database on the client's server and
>when we try to access any component of the "restored" database, we receive
>the SQL-DMO 21776 error. Which states the following
>"Error 21776: [SQL-DMO} The name 'CDR-Prod' was not found in the Databases
>colelction. If the name is a qualified name, use [ ] to separate various
>parts of the name and try again."
>So what i am looking for is what is the best mechanism to move our database
>from out SQL Server 2000 environment to the clients SQL Server 2000
>environment where we can preserve the table structure and data contained
>within the database.
>As well, how can we delete the database that we were able to create but now
>is not recognized by the Enterprise manager due to the 21776 error.
>I hope this provides a more detailed explanation of the situation we are
>facing.
>Thanks for the assistance,
>Rod
>"Sue Hoegemeier" wrote:
>> Please post the entire error message. Error 21776 is the
>> generic error used for an object not found in a collection.
>> The specifics of what object in what collection would be in
>> the entire error message.
>> -Sue
>> On Sun, 13 Mar 2005 18:55:02 -0800, "Rod S" <Rod
>> S@.discussions.microsoft.com> wrote:
>> >Hi,
>> >
>> >We have a database that we built for a client and we would like to make a
>> >backup of the database and restore the database on our clients Sql Server
>> >box. Both environments are running SQL Server 2000 SP3a.
>> >
>> >We make a backup of the database on our server and when we go to the clients
>> >site and run the restore it complains and gives an error message that states
>> >SQL-DMO (ODBC SQLState: 42000) and states we should use the WITH MOVE. We
>> >tried the WITH MOVE but aree not experienced DBA so we are not sure if we
>> >configured it right.
>> >
>> >RESTORE DATABASE TEST FROM DISK='C:\TEMP\CDR-Prod.BAK'
>> >WITH MOVE 'TEST_Data' TO 'c:\program files\microsoft sql
>> >server\mssql\data\CDR-Prod_Data.MDF',
>> >MOVE 'TEST_Log' TO ' c:\program files\microsoft sql
>> >server\mssql\data\CDR-Prod_Log.LDF'
>> >
>> >
>> >We were able to restore the database some how and then it gives us an
>> >SQL-DMO error 21776.
>> >
>> >Any ideas on how we should best approach this situation so that we can get
>> >the full database (structure and data)?
>> >
>> >Thanks for the assistance.
>>
Move Database to client
We have a database that we built for a client and we would like to make a
backup of the database and restore the database on our clients Sql Server
box. Both environments are running SQL Server 2000 SP3a.
We make a backup of the database on our server and when we go to the clients
site and run the restore it complains and gives an error message that states
SQL-DMO (ODBC SQLState: 42000) and states we should use the WITH MOVE. We
tried the WITH MOVE but aree not experienced DBA so we are not sure if we
configured it right.
RESTORE DATABASE TEST FROM DISK='C:\TEMP\CDR-Prod.BAK'
WITH MOVE 'TEST_Data' TO 'c:\program files\microsoft sql
server\mssql\data\CDR-Prod_Data.MDF',
MOVE 'TEST_Log' TO ' c:\program files\microsoft sql
server\mssql\data\CDR-Prod_Log.LDF'
We were able to restore the database some how and then it gives us an
SQL-DMO error 21776.
Any ideas on how we should best approach this situation so that we can get
the full database (structure and data)?
Thanks for the assistance.
Please post the entire error message. Error 21776 is the
generic error used for an object not found in a collection.
The specifics of what object in what collection would be in
the entire error message.
-Sue
On Sun, 13 Mar 2005 18:55:02 -0800, "Rod S" <Rod
S@.discussions.microsoft.com> wrote:
>Hi,
>We have a database that we built for a client and we would like to make a
>backup of the database and restore the database on our clients Sql Server
>box. Both environments are running SQL Server 2000 SP3a.
>We make a backup of the database on our server and when we go to the clients
>site and run the restore it complains and gives an error message that states
>SQL-DMO (ODBC SQLState: 42000) and states we should use the WITH MOVE. We
>tried the WITH MOVE but aree not experienced DBA so we are not sure if we
>configured it right.
>RESTORE DATABASE TEST FROM DISK='C:\TEMP\CDR-Prod.BAK'
>WITH MOVE 'TEST_Data' TO 'c:\program files\microsoft sql
>server\mssql\data\CDR-Prod_Data.MDF',
>MOVE 'TEST_Log' TO ' c:\program files\microsoft sql
>server\mssql\data\CDR-Prod_Log.LDF'
>
>We were able to restore the database some how and then it gives us an
>SQL-DMO error 21776.
>Any ideas on how we should best approach this situation so that we can get
>the full database (structure and data)?
>Thanks for the assistance.
|||Hi,
Sorry Sue, I should have elaborated more:
We have two problems:
1. we areunable to restore the database properly using either the GUI based
restore tool in the Enterprise Manager or usign the Query Analyzer with the
script included.
2. We some how managed to restore the database on the client's server and
when we try to access any component of the "restored" database, we receive
the SQL-DMO 21776 error. Which states the following
"Error 21776: [SQL-DMO} The name 'CDR-Prod' was not found in the Databases
colelction. If the name is a qualified name, use [ ] to separate various
parts of the name and try again."
So what i am looking for is what is the best mechanism to move our database
from out SQL Server 2000 environment to the clients SQL Server 2000
environment where we can preserve the table structure and data contained
within the database.
As well, how can we delete the database that we were able to create but now
is not recognized by the Enterprise manager due to the 21776 error.
I hope this provides a more detailed explanation of the situation we are
facing.
Thanks for the assistance,
Rod
"Sue Hoegemeier" wrote:
> Please post the entire error message. Error 21776 is the
> generic error used for an object not found in a collection.
> The specifics of what object in what collection would be in
> the entire error message.
> -Sue
> On Sun, 13 Mar 2005 18:55:02 -0800, "Rod S" <Rod
> S@.discussions.microsoft.com> wrote:
>
>
|||The best mechanism is a backup and restore. You can also use
sp_detach_db, copy the data and log files and have the
client attach the files with sp_attach_db.
I would guess many of the problems are from having a
non-standard database name. The rules for identifier and
what characters are allowed in what positions is in the
books online topic: Using Identifiers
In terms of how to delete the database now, try dropping the
database using query analyzer and putting brackets around
the database name.
drop database [CDR-Prod]
-Sue
On Mon, 14 Mar 2005 08:11:05 -0800, "Rod S"
<RodS@.discussions.microsoft.com> wrote:
[vbcol=seagreen]
>Hi,
>Sorry Sue, I should have elaborated more:
>We have two problems:
>1. we areunable to restore the database properly using either the GUI based
>restore tool in the Enterprise Manager or usign the Query Analyzer with the
>script included.
>2. We some how managed to restore the database on the client's server and
>when we try to access any component of the "restored" database, we receive
>the SQL-DMO 21776 error. Which states the following
>"Error 21776: [SQL-DMO} The name 'CDR-Prod' was not found in the Databases
>colelction. If the name is a qualified name, use [ ] to separate various
>parts of the name and try again."
>So what i am looking for is what is the best mechanism to move our database
>from out SQL Server 2000 environment to the clients SQL Server 2000
>environment where we can preserve the table structure and data contained
>within the database.
>As well, how can we delete the database that we were able to create but now
>is not recognized by the Enterprise manager due to the 21776 error.
>I hope this provides a more detailed explanation of the situation we are
>facing.
>Thanks for the assistance,
>Rod
>"Sue Hoegemeier" wrote:
Move Database to client
We have a database that we built for a client and we would like to make a
backup of the database and restore the database on our clients Sql Server
box. Both environments are running SQL Server 2000 SP3a.
We make a backup of the database on our server and when we go to the clients
site and run the restore it complains and gives an error message that states
SQL-DMO (ODBC SQLState: 42000) and states we should use the WITH MOVE. We
tried the WITH MOVE but aree not experienced DBA so we are not sure if we
configured it right.
RESTORE DATABASE TEST FROM DISK='C:\TEMP\CDR-Prod.BAK'
WITH MOVE 'TEST_Data' TO 'c:\program files\microsoft sql
server\mssql\data\CDR-Prod_Data.MDF',
MOVE 'TEST_Log' TO ' c:\program files\microsoft sql
server\mssql\data\CDR-Prod_Log.LDF'
We were able to restore the database some how and then it gives us an
SQL-DMO error 21776.
Any ideas on how we should best approach this situation so that we can get
the full database (structure and data)?
Thanks for the assistance.Please post the entire error message. Error 21776 is the
generic error used for an object not found in a collection.
The specifics of what object in what collection would be in
the entire error message.
-Sue
On Sun, 13 Mar 2005 18:55:02 -0800, "Rod S" <Rod
S@.discussions.microsoft.com> wrote:
>Hi,
>We have a database that we built for a client and we would like to make a
>backup of the database and restore the database on our clients Sql Server
>box. Both environments are running SQL Server 2000 SP3a.
>We make a backup of the database on our server and when we go to the client
s
>site and run the restore it complains and gives an error message that state
s
>SQL-DMO (ODBC SQLState: 42000) and states we should use the WITH MOVE. We
>tried the WITH MOVE but aree not experienced DBA so we are not sure if we
>configured it right.
>RESTORE DATABASE TEST FROM DISK='C:\TEMP\CDR-Prod.BAK'
>WITH MOVE 'TEST_Data' TO 'c:\program files\microsoft sql
>server\mssql\data\CDR-Prod_Data.MDF',
>MOVE 'TEST_Log' TO ' c:\program files\microsoft sql
>server\mssql\data\CDR-Prod_Log.LDF'
>
>We were able to restore the database some how and then it gives us an
>SQL-DMO error 21776.
>Any ideas on how we should best approach this situation so that we can get
>the full database (structure and data)?
>Thanks for the assistance.|||Hi,
Sorry Sue, I should have elaborated more:
We have two problems:
1. we areunable to restore the database properly using either the GUI based
restore tool in the Enterprise Manager or usign the Query Analyzer with the
script included.
2. We some how managed to restore the database on the client's server and
when we try to access any component of the "restored" database, we receive
the SQL-DMO 21776 error. Which states the following
"Error 21776: [SQL-DMO} The name 'CDR-Prod' was not found in the Databas
es
colelction. If the name is a qualified name, use [ ] to separate variou
s
parts of the name and try again."
So what i am looking for is what is the best mechanism to move our database
from out SQL Server 2000 environment to the clients SQL Server 2000
environment where we can preserve the table structure and data contained
within the database.
As well, how can we delete the database that we were able to create but now
is not recognized by the Enterprise manager due to the 21776 error.
I hope this provides a more detailed explanation of the situation we are
facing.
Thanks for the assistance,
Rod
"Sue Hoegemeier" wrote:
> Please post the entire error message. Error 21776 is the
> generic error used for an object not found in a collection.
> The specifics of what object in what collection would be in
> the entire error message.
> -Sue
> On Sun, 13 Mar 2005 18:55:02 -0800, "Rod S" <Rod
> S@.discussions.microsoft.com> wrote:
>
>|||The best mechanism is a backup and restore. You can also use
sp_detach_db, copy the data and log files and have the
client attach the files with sp_attach_db.
I would guess many of the problems are from having a
non-standard database name. The rules for identifier and
what characters are allowed in what positions is in the
books online topic: Using Identifiers
In terms of how to delete the database now, try dropping the
database using query analyzer and putting brackets around
the database name.
drop database [CDR-Prod]
-Sue
On Mon, 14 Mar 2005 08:11:05 -0800, "Rod S"
<RodS@.discussions.microsoft.com> wrote:
[vbcol=seagreen]
>Hi,
>Sorry Sue, I should have elaborated more:
>We have two problems:
>1. we areunable to restore the database properly using either the GUI based
>restore tool in the Enterprise Manager or usign the Query Analyzer with the
>script included.
>2. We some how managed to restore the database on the client's server and
>when we try to access any component of the "restored" database, we receive
>the SQL-DMO 21776 error. Which states the following
>"Error 21776: [SQL-DMO} The name 'CDR-Prod' was not found in the Databa
ses
>colelction. If the name is a qualified name, use [ ] to separate vario
us
>parts of the name and try again."
>So what i am looking for is what is the best mechanism to move our database
>from out SQL Server 2000 environment to the clients SQL Server 2000
>environment where we can preserve the table structure and data contained
>within the database.
>As well, how can we delete the database that we were able to create but now
>is not recognized by the Enterprise manager due to the 21776 error.
>I hope this provides a more detailed explanation of the situation we are
>facing.
>Thanks for the assistance,
>Rod
>"Sue Hoegemeier" wrote:
>
Move database to another partition
partitions. I then installed Sharepoint which installed a database and put it
in the default location on the c: partition. I would like to move this to d:.
I have tried to do this by detaching and attaching, and also by backing and
restoring, but both the attach and the backup dialog boxes only allow me to
browse the c: drive. Is this a feature of Standard Edition? Do I need to use
Enterprise? Or is there a configuration setting I can change somewhere?
TIA25degc wrote:
> I have recently installed SQL Server 2005 Standard Edition on a server with 2
> partitions. I then installed Sharepoint which installed a database and put it
> in the default location on the c: partition. I would like to move this to d:.
> I have tried to do this by detaching and attaching, and also by backing and
> restoring, but both the attach and the backup dialog boxes only allow me to
> browse the c: drive. Is this a feature of Standard Edition? Do I need to use
> Enterprise? Or is there a configuration setting I can change somewhere?
> TIA
Not sure why you can't browse your other drive, but a workaround would
be to not use the GUI to do this. Instead use the SQL commands to
detach/reattach the database:
EXEC sp_detach_db DBname, 'true'
Copy the files from C: to D:
EXEC sp_attach_db @.dbname = 'DBName', @.filename1 = 'D:\MDFFile',
@.filename2 = 'D:\LDFFile'|||Thanks. This highlighted an issue with the d: drive. Although
readable/writable through Windows I decided to reformat, and now it is
working fine.
Thanks for your help.
"Tracy McKibben" wrote:
> 25degc wrote:
> > I have recently installed SQL Server 2005 Standard Edition on a server with 2
> > partitions. I then installed Sharepoint which installed a database and put it
> > in the default location on the c: partition. I would like to move this to d:.
> > I have tried to do this by detaching and attaching, and also by backing and
> > restoring, but both the attach and the backup dialog boxes only allow me to
> > browse the c: drive. Is this a feature of Standard Edition? Do I need to use
> > Enterprise? Or is there a configuration setting I can change somewhere?
> >
> > TIA
> Not sure why you can't browse your other drive, but a workaround would
> be to not use the GUI to do this. Instead use the SQL commands to
> detach/reattach the database:
> EXEC sp_detach_db DBname, 'true'
> Copy the files from C: to D:
> EXEC sp_attach_db @.dbname = 'DBName', @.filename1 = 'D:\MDFFile',
> @.filename2 = 'D:\LDFFile'
>
Move database to another partition
> I have recently installed SQL Server 2005 Standard Edition on a server wit
h 2
> partitions. I then installed Sharepoint which installed a database and put
it
> in the default location on the c: partition. I would like to move this to
d:.
> I have tried to do this by detaching and attaching, and also by backing an
d
> restoring, but both the attach and the backup dialog boxes only allow me t
o
> browse the c: drive. Is this a feature of Standard Edition? Do I need to u
se
> Enterprise? Or is there a configuration setting I can change somewhere?
> TIA
Not sure why you can't browse your other drive, but a workaround would
be to not use the GUI to do this. Instead use the SQL commands to
detach/reattach the database:
EXEC sp_detach_db DBname, 'true'
Copy the files from C: to D:
EXEC sp_attach_db @.dbname = 'DBName', @.filename1 = 'D:\MDFFile',
@.filename2 = 'D:\LDFFile'I have recently installed SQL Server 2005 Standard Edition on a server with
2
partitions. I then installed Sharepoint which installed a database and put i
t
in the default location on the c: partition. I would like to move this to d:
.
I have tried to do this by detaching and attaching, and also by backing and
restoring, but both the attach and the backup dialog boxes only allow me to
browse the c: drive. Is this a feature of Standard Edition? Do I need to use
Enterprise? Or is there a configuration setting I can change somewhere?
TIA|||25degc wrote:
> I have recently installed SQL Server 2005 Standard Edition on a server wit
h 2
> partitions. I then installed Sharepoint which installed a database and put
it
> in the default location on the c: partition. I would like to move this to
d:.
> I have tried to do this by detaching and attaching, and also by backing an
d
> restoring, but both the attach and the backup dialog boxes only allow me t
o
> browse the c: drive. Is this a feature of Standard Edition? Do I need to u
se
> Enterprise? Or is there a configuration setting I can change somewhere?
> TIA
Not sure why you can't browse your other drive, but a workaround would
be to not use the GUI to do this. Instead use the SQL commands to
detach/reattach the database:
EXEC sp_detach_db DBname, 'true'
Copy the files from C: to D:
EXEC sp_attach_db @.dbname = 'DBName', @.filename1 = 'D:\MDFFile',
@.filename2 = 'D:\LDFFile'|||Thanks. This highlighted an issue with the d: drive. Although
readable/writable through Windows I decided to reformat, and now it is
working fine.
Thanks for your help.
"Tracy McKibben" wrote:
> 25degc wrote:
> Not sure why you can't browse your other drive, but a workaround would
> be to not use the GUI to do this. Instead use the SQL commands to
> detach/reattach the database:
> EXEC sp_detach_db DBname, 'true'
> Copy the files from C: to D:
> EXEC sp_attach_db @.dbname = 'DBName', @.filename1 = 'D:\MDFFile',
> @.filename2 = 'D:\LDFFile'
>|||Thanks. This highlighted an issue with the d: drive. Although
readable/writable through Windows I decided to reformat, and now it is
working fine.
Thanks for your help.
"Tracy McKibben" wrote:
> 25degc wrote:
> Not sure why you can't browse your other drive, but a workaround would
> be to not use the GUI to do this. Instead use the SQL commands to
> detach/reattach the database:
> EXEC sp_detach_db DBname, 'true'
> Copy the files from C: to D:
> EXEC sp_attach_db @.dbname = 'DBName', @.filename1 = 'D:\MDFFile',
> @.filename2 = 'D:\LDFFile'
>
Move database to a different drive
Someone installed all the data base on the C: drive, Which is now running
out of space. I need to move them to the D: drive.
I found this http://support.microsoft.com/default.aspx?scid=kb;en-us;224071
but it unclear if i need to move just my created database or all of the
database.
I really need a step by step instructions if possable - its a windows 2000
box running sql 2000.
thanks
leeyou can detach \ reattach (See SQL Books On Line)
OR you can do a Backup and RESTORE with "MOVE"
Again, see SQL Books On Line
Greg Jackson
PDX, Oregon|||Move whatever databases you need based on space usage requirements. The
article is pretty self-explanatory. You may move one or all of your user
databases.
--
Geoff N. Hiten
Microsoft SQL Server MVP
Senior Database Administrator
Careerbuilder.com
I support the Professional Association for SQL Server
www.sqlpass.org
"Lee" <Lee@.discussions.microsoft.com> wrote in message
news:2E6E3840-CBB0-4FBE-BC92-E0B45A3ED4E8@.microsoft.com...
> Hi,
> Someone installed all the data base on the C: drive, Which is now running
> out of space. I need to move them to the D: drive.
> I found this
http://support.microsoft.com/default.aspx?scid=kb;en-us;224071
> but it unclear if i need to move just my created database or all of the
> database.
> I really need a step by step instructions if possable - its a windows 2000
> box running sql 2000.
> thanks
> lee|||Hi,
1.First,detach your database using
EXEC sp_detach_db '<<dbname>>', 'true'
2. Move your mdf file & ldf file from c: drive to other partition where you
have space. it is recommended to have mdf & ldf on different folder.
3. Once you copied in to appropriate drives then attach your database using
EXEC sp_attach_db @.dbname = N'<<dbname>>',
@.filename1 = N'<<D:\destinationfolder\dbdata.mdf',
@.filename2 = N'<<E:\destinationfolder\dblog.ldf'
after running this scripts you should see your database running fine as
normal.
Best of luck!
S.Lakshminarayanan.
--
Message posted via http://www.sqlmonster.com
Move database to a different drive
Someone installed all the data base on the C: drive, Which is now running
out of space. I need to move them to the D: drive.
I found this http://support.microsoft.com/default...b;en-us;224071
but it unclear if i need to move just my created database or all of the
database.
I really need a step by step instructions if possable - its a windows 2000
box running sql 2000.
thanks
lee
you can detach \ reattach (See SQL Books On Line)
OR you can do a Backup and RESTORE with "MOVE"
Again, see SQL Books On Line
Greg Jackson
PDX, Oregon
|||Move whatever databases you need based on space usage requirements. The
article is pretty self-explanatory. You may move one or all of your user
databases.
Geoff N. Hiten
Microsoft SQL Server MVP
Senior Database Administrator
Careerbuilder.com
I support the Professional Association for SQL Server
www.sqlpass.org
"Lee" <Lee@.discussions.microsoft.com> wrote in message
news:2E6E3840-CBB0-4FBE-BC92-E0B45A3ED4E8@.microsoft.com...
> Hi,
> Someone installed all the data base on the C: drive, Which is now running
> out of space. I need to move them to the D: drive.
> I found this
http://support.microsoft.com/default...b;en-us;224071
> but it unclear if i need to move just my created database or all of the
> database.
> I really need a step by step instructions if possable - its a windows 2000
> box running sql 2000.
> thanks
> lee
|||Hi,
1.First,detach your database using
EXEC sp_detach_db '<<dbname>>', 'true'
2. Move your mdf file & ldf file from c: drive to other partition where you
have space. it is recommended to have mdf & ldf on different folder.
3. Once you copied in to appropriate drives then attach your database using
EXEC sp_attach_db @.dbname = N'<<dbname>>',
@.filename1 = N'<<D:\destinationfolder\dbdata.mdf',
@.filename2 = N'<<E:\destinationfolder\dblog.ldf'
after running this scripts you should see your database running fine as
normal.
Best of luck!
S.Lakshminarayanan.
Message posted via http://www.sqlmonster.com
Move database to a different drive
Someone installed all the data base on the C: drive, Which is now running
out of space. I need to move them to the D: drive.
I found this http://support.microsoft.com/defaul...kb;en-us;224071
but it unclear if i need to move just my created database or all of the
database.
I really need a step by step instructions if possable - its a windows 2000
box running sql 2000.
thanks
leeyou can detach \ reattach (See SQL Books On Line)
OR you can do a Backup and RESTORE with "MOVE"
Again, see SQL Books On Line
Greg Jackson
PDX, Oregon|||Move whatever databases you need based on space usage requirements. The
article is pretty self-explanatory. You may move one or all of your user
databases.
Geoff N. Hiten
Microsoft SQL Server MVP
Senior Database Administrator
Careerbuilder.com
I support the Professional Association for SQL Server
www.sqlpass.org
"Lee" <Lee@.discussions.microsoft.com> wrote in message
news:2E6E3840-CBB0-4FBE-BC92-E0B45A3ED4E8@.microsoft.com...
> Hi,
> Someone installed all the data base on the C: drive, Which is now running
> out of space. I need to move them to the D: drive.
> I found this
http://support.microsoft.com/defaul...kb;en-us;224071
> but it unclear if i need to move just my created database or all of the
> database.
> I really need a step by step instructions if possable - its a windows 2000
> box running sql 2000.
> thanks
> lee|||Hi,
1.First,detach your database using
EXEC sp_detach_db '<<dbname>>', 'true'
2. Move your mdf file & ldf file from c: drive to other partition where you
have space. it is recommended to have mdf & ldf on different folder.
3. Once you copied in to appropriate drives then attach your database using
EXEC sp_attach_db @.dbname = N'<<dbname>>',
@.filename1 = N'<<D:\destinationfolder\dbdata.mdf',
@.filename2 = N'<<E:\destinationfolder\dblog.ldf'
after running this scripts you should see your database running fine as
normal.
Best of luck!
S.Lakshminarayanan.
Message posted via http://www.droptable.com
Move Database Store
anyone please tell me what I have to do to relocate the entire store? Let's
assume that I want to move everything from F:\SQLDATA to G:\SQLDATA. Can I
stop SQL server
xcopy f:\sqldata g:\sqldata /e /i
point SQL to G:\SQLDATA
start SQL server
Life is good
If so, how and where do I reset where SQL looks for the files? in step 3?
How to move SQL Server databases to a new location by using Detach and
Attach functions in SQL Server
http://support.microsoft.com/kb/224071/en-us
Note that the system databases each have special considerations.
Geoff N. Hiten
Senior Database Administrator
Microsoft SQL Server MVP
"de Graff" <rjdegraff@.hydro.mb.ca> wrote in message
news:uLsVDeHSGHA.196@.TK2MSFTNGP10.phx.gbl...
> We are replacing our drive arrays on our production SQL 2000 server. Can
> anyone please tell me what I have to do to relocate the entire store?
> Let's assume that I want to move everything from F:\SQLDATA to G:\SQLDATA.
> Can I
> stop SQL server
> xcopy f:\sqldata g:\sqldata /e /i
> point SQL to G:\SQLDATA
> start SQL server
> Life is good
> If so, how and where do I reset where SQL looks for the files? in step 3?
>
|||Exactly what I was looking for. Thanks.
"Geoff N. Hiten" <SQLCraftsman@.gmail.com> wrote in message
news:uikhynHSGHA.1844@.TK2MSFTNGP12.phx.gbl...
> How to move SQL Server databases to a new location by using Detach and
> Attach functions in SQL Server
> http://support.microsoft.com/kb/224071/en-us
> Note that the system databases each have special considerations.
> --
> Geoff N. Hiten
> Senior Database Administrator
> Microsoft SQL Server MVP
>
> "de Graff" <rjdegraff@.hydro.mb.ca> wrote in message
> news:uLsVDeHSGHA.196@.TK2MSFTNGP10.phx.gbl...
>
|||We use a vendor program called Misys. Recently we migrated to a larger
server with multiple RAID arrays. The application install puts the program
and database files on the same drive. We needed to move the log files and
databases to their own drives.
I see others proposing methods using SQL, but we found that the following
worked well without requiring any SQL programming.
1) Stopped the Misys Server service.
2) Using SQL Server Agent, backed up the database
3) Detached the database
4) Moved the MDF And LDF files to the new locations
5) Re-attached the database. Adjusted the MDF and LDF file locations to the
new ones
6) Re-started the service
7) Adjusted (as needed) any SQL Server Agent jobs that backed up and
compressed the database
Regards,
Hank Arnold
"de Graff" <rjdegraff@.hydro.mb.ca> wrote in message
news:uLsVDeHSGHA.196@.TK2MSFTNGP10.phx.gbl...
> We are replacing our drive arrays on our production SQL 2000 server. Can
> anyone please tell me what I have to do to relocate the entire store?
> Let's assume that I want to move everything from F:\SQLDATA to G:\SQLDATA.
> Can I
> stop SQL server
> xcopy f:\sqldata g:\sqldata /e /i
> point SQL to G:\SQLDATA
> start SQL server
> Life is good
> If so, how and where do I reset where SQL looks for the files? in step 3?
>
move database record
i have no problem to select all records from the table, but how to copy or move these selected records to other table which contain same field as the orriginal.
thanksINSERT INTO table2 (col1, col2, col3...)
SELECT col1,col2, col3
FROM table1
WHERE ...|||ndinakar, can u guide me more details. example i have one table call student, inside got id and name and move this record to a table call student2. can u guide me complete sql statement, because i new to the sql, i bit confuse in line 1 and line 2. thanks
INSERT INTO table2 (col1, col2, col3...)
SELECT col1,col2, col3
FROM table1
WHERE ...|||
INSERT INTO student2 (id,name)
SELECT id,name
FROM student
WHERE {something}
{something} could be ID=some number or name='some name' etc
|||is't this method is for one reord only? how about if i want to move 1000 records from table student to table student2 ?. thanks|||You move as many records as your SELECT statement returns.
Move Database From Standard To Express
Express Edition installed at home for doing work on the databases after hours.
Is it possible to copy/export the database from the Standard Edition to the
Express Edition and back?
What happens if the database is more than 4Gb?Hi
see the link bellow
http://msdn2.microsoft.com/en-us/library/ms143393.aspx
it is not possible to do this.
What happens if the database is more than 4Gb
Server throws an error message saying that insufficient disk space or file
has reach its limit ,some thing like that.
in 2000 msde you can work around this by adding one more data file to the
file group. but i haven't tested this on sql express
VT
Knowledge is power, share it...
http://oneplace4sql.blogspot.com/
"Hiwj" <Hiwj@.discussions.microsoft.com> wrote in message
news:7DDA6F6E-BC8F-4F61-8670-FAC5C830E63F@.microsoft.com...
> Our company uses MS SQL 2005 Standard for various databases. I've got the
> Express Edition installed at home for doing work on the databases after
> hours.
> Is it possible to copy/export the database from the Standard Edition to
> the
> Express Edition and back?
> What happens if the database is more than 4Gb?
>
Move Database From Standard To Express
Express Edition installed at home for doing work on the databases after hour
s.
Is it possible to copy/export the database from the Standard Edition to the
Express Edition and back?
What happens if the database is more than 4Gb?Hi
see the link bellow
http://msdn2.microsoft.com/en-us/library/ms143393.aspx
it is not possible to do this.
What happens if the database is more than 4Gb
Server throws an error message saying that insufficient disk space or file
has reach its limit ,some thing like that.
in 2000 msde you can work around this by adding one more data file to the
file group. but i haven't tested this on sql express
VT
Knowledge is power, share it...
http://oneplace4sql.blogspot.com/
"Hiwj" <Hiwj@.discussions.microsoft.com> wrote in message
news:7DDA6F6E-BC8F-4F61-8670-FAC5C830E63F@.microsoft.com...
> Our company uses MS SQL 2005 Standard for various databases. I've got the
> Express Edition installed at home for doing work on the databases after
> hours.
> Is it possible to copy/export the database from the Standard Edition to
> the
> Express Edition and back?
> What happens if the database is more than 4Gb?
>
Move database from SQLS2k5 to SQLS2k5Express
Hello,
1.) Can I move a database complete with tables, diagrams, relationships, stored procedures, etc. from SQL Server 2005 to SQL Server 2005 Express and preserve all the work I did?
2.) Can I do the same from SQL Server 2000 to SQL Server 2005 Express and preserve all the work I did?
Thank you,
dbuchanan
Hi, there should be no problem with either of these scenarios, the only thing to be careful of are the restrictions in SQL Server Express.
Most restrictions are around size and performance, ie 4GB database size, 1 CPU, 1GB Buffer Cache, but there are also some others for instance, SQL Server Express does NOT support SSIS (DTS in SQL Server 2000), so if you are using these features of SQL Server Express, it would not be a simple move.
For more information on SQL Server Express features, see the books online http://msdn2.microsoft.com/en-us/ms165636(SQL.90).aspx
|||As Scott says this is very doable. You can use detach/attach functionality or the Copy Database Wizard for this pretty easily.|||That isn't actually true, at all.
I've been fighting with SQL express for 3 days now to try and get it to attach a database correctly.
Firstly it will not attach it as a System Database, it creates a new instance for it, which while weird I understand.
Then when any script connects its throws this error :
Could not locate entry in sysdatabases for database 'attacheddatabase'. No entry found with that name. Make sure that the name is entered correctly. (severity 16)
Unless you connect to the system databases then it allows you to select the databases, though your not allowed to copy any tables, or move any databases to that area ........
Oh how I pray for a actual developer focused database from MS, i.e. one that has permissions that allow you do to what you want opposed to hindering you every step of the way ........
I'm fighting tooth and nail to get this whole project moved to a decent database now.
|||Jemue, what connection string are you using to connect to your databse?
I have used SQL Express extensively, and never had any real problems connecting to database, but the user instance feature can get a bit confusing at times. Maybe if you give me a bit more detail about what you're trying to achieve, what technologies you are using, we may be able to help.
Also keep in mind that you don't have to use User instances, you can just connect to a database in exactly the same way you do in any other SKU of SQL Server.
Cheers
|||Moving database from SQLS2k5 to SQLS2k5Express may be not easy!
I have obtained customer DB which was detached from SQL2K and attached it to SQL2005 Express.
I found that all tables are presented in form DBA.<table name> and simplest query
SELECT * FROM <table name>
results in error message saying something like "object name <table name> is incorrect" while query
SELECT * FROM DBA.<table name>
goes successfully.
Well, what should be done in this case?
Thank you.
Move database from SQLS2k5 to SQLS2k5Express
Hello,
1.) Can I move a database complete with tables, diagrams, relationships, stored procedures, etc. from SQL Server 2005 to SQL Server 2005 Express and preserve all the work I did?
2.) Can I do the same from SQL Server 2000 to SQL Server 2005 Express and preserve all the work I did?
Thank you,
dbuchanan
Hi, there should be no problem with either of these scenarios, the only thing to be careful of are the restrictions in SQL Server Express.
Most restrictions are around size and performance, ie 4GB database size, 1 CPU, 1GB Buffer Cache, but there are also some others for instance, SQL Server Express does NOT support SSIS (DTS in SQL Server 2000), so if you are using these features of SQL Server Express, it would not be a simple move.
For more information on SQL Server Express features, see the books online http://msdn2.microsoft.com/en-us/ms165636(SQL.90).aspx
|||As Scott says this is very doable. You can use detach/attach functionality or the Copy Database Wizard for this pretty easily.|||That isn't actually true, at all.
I've been fighting with SQL express for 3 days now to try and get it to attach a database correctly.
Firstly it will not attach it as a System Database, it creates a new instance for it, which while weird I understand.
Then when any script connects its throws this error :
Could not locate entry in sysdatabases for database 'attacheddatabase'. No entry found with that name. Make sure that the name is entered correctly. (severity 16)
Unless you connect to the system databases then it allows you to select the databases, though your not allowed to copy any tables, or move any databases to that area ........
Oh how I pray for a actual developer focused database from MS, i.e. one that has permissions that allow you do to what you want opposed to hindering you every step of the way ........
I'm fighting tooth and nail to get this whole project moved to a decent database now.
|||Jemue, what connection string are you using to connect to your databse?
I have used SQL Express extensively, and never had any real problems connecting to database, but the user instance feature can get a bit confusing at times. Maybe if you give me a bit more detail about what you're trying to achieve, what technologies you are using, we may be able to help.
Also keep in mind that you don't have to use User instances, you can just connect to a database in exactly the same way you do in any other SKU of SQL Server.
Cheers
|||Moving database from SQLS2k5 to SQLS2k5Express may be not easy!
I have obtained customer DB which was detached from SQL2K and attached it to SQL2005 Express.
I found that all tables are presented in form DBA.<table name> and simplest query
SELECT * FROM <table name>
results in error message saying something like "object name <table name> is incorrect" while query
SELECT * FROM DBA.<table name>
goes successfully.
Well, what should be done in this case?
Thank you.