Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Is it safe..?

Status
Not open for further replies.

kenjoswe

Technical User
Sep 19, 2000
327
SE
Hi all,

I would like to move TempDb from C:\MyPath to D:\MyPath

This is what I have planned to do:
1.) Detach the tempdb database
2.) Move tempdb
3.) Attach tempdb

/Kent J.
 
The detach won't work (so I gues it's afe'.

To move tempdb
alter database tempdb modify file (name='tempdb', filename='<path>\tempDB.MDF')
alter database tempdb modify file (name='templog', filename= '<path>\TempDB.LDF')

It will be recreated on restart and you can delete the old files.


======================================
Cursors are useful if you don't know sql.
DTS can be used in a similar way.
Beer is not cold and it isn't fizzy.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top