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

 All Forums
 SQL Server 2005 Forums
 SQL Server Administration (2005)
 Transferring data from .mdf to .ndf file

Author  Topic 

ksr39
Posting Yak Master

193 Posts

Posted - 2011-09-22 : 08:45:41
Hi All,

I have a database in which the .mdf file is very big I added a .ndf secondary file in the other drive so that there can not be any problem. But I want to send some of the data from .mdf file to .ndf file how can I do that, if there is any process please let me know it will be a great help for me.

Thanking you in advance.

russell
Pyro-ma-ni-yak

5072 Posts

Posted - 2011-09-22 : 08:48:30
To move a table from one filegroup to the other, drop, then recreate the clustered index on the secondary filegroup.
Go to Top of Page

ksr39
Posting Yak Master

193 Posts

Posted - 2011-09-22 : 09:02:44
Do i need to drop the clustered index and recreate it on the secondary file,if so my data will be moved to the secondary file automatically.
Go to Top of Page

russell
Pyro-ma-ni-yak

5072 Posts

Posted - 2011-09-22 : 09:54:05
yes
Go to Top of Page

GilaMonster
Master Smack Fu Yak Hacker

4507 Posts

Posted - 2011-09-22 : 10:24:15
Is the ndf in a separate filegroup or is it part of the primary filegroup?

--
Gail Shaw
SQL Server MVP
Go to Top of Page

ksr39
Posting Yak Master

193 Posts

Posted - 2011-09-22 : 11:19:27
Its the part of primary file group.as i created it because there is no enough space in the drive where the .mdf resides so i created one .ndf file in another drive and i need to transfer some data from the .mdf to free the space in the perticular drive.
Go to Top of Page

russell
Pyro-ma-ni-yak

5072 Posts

Posted - 2011-09-22 : 12:32:24
You can't specify the file, only the filegroup to place objects on.
Go to Top of Page
   

- Advertisement -