| Author |
Topic |
|
anuradhay
Starting Member
41 Posts |
Posted - 2004-12-09 : 03:03:28
|
| Hi,I have a database which has one mdf and say 2 ndfs. i am taking backup of this and trying to restore it as another database. now i don't want have mdf and ndf files in the new database. i want to merge it . is it possiblethanks, |
|
|
Kristen
Test
22859 Posts |
Posted - 2004-12-09 : 05:32:46
|
| Duplicate of http://www.sqlteam.com/forums/topic.asp?TOPIC_ID=43510 |
 |
|
|
anuradhay
Starting Member
41 Posts |
Posted - 2004-12-09 : 06:04:03
|
| s i know. it is me who posted it there.. |
 |
|
|
Kristen
Test
22859 Posts |
Posted - 2004-12-09 : 06:52:20
|
| Yeah, but folk here will get confused answering it in different places ...Kristen |
 |
|
|
anuradhay
Starting Member
41 Posts |
Posted - 2004-12-09 : 23:15:37
|
| ok. but i thought it will not be missed. do u have an answer for this. |
 |
|
|
nr
SQLTeam MVY
12543 Posts |
Posted - 2004-12-09 : 23:17:02
|
| You have to restore it then remove the files you don't want.==========================================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. |
 |
|
|
anuradhay
Starting Member
41 Posts |
Posted - 2004-12-10 : 00:22:28
|
| No. i don't want to remove the files. if i remove the files then i will miss some data which is residing in that file. i want to merge these files. |
 |
|
|
nr
SQLTeam MVY
12543 Posts |
Posted - 2004-12-10 : 00:29:07
|
| You won't lose data. a feature of databases is they don't allow that.It won't allow you to drop a file unless all the data is migrated to other files.See dbcc shrinkfile in bol==========================================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. |
 |
|
|
anuradhay
Starting Member
41 Posts |
Posted - 2004-12-10 : 01:59:43
|
| I am not dropping the files. i have two files. one primary and one secondary. i want to restore both the files. but the new database should not have 2 different files. it should have only one mdf, which should also have the content of ndf. |
 |
|
|
jen
Master Smack Fu Yak Hacker
4110 Posts |
Posted - 2004-12-10 : 02:55:36
|
| http://www.sqlteam.com/forums/topic.asp?TOPIC_ID=43510--------------------keeping it simple... |
 |
|
|
nr
SQLTeam MVY
12543 Posts |
Posted - 2004-12-10 : 10:37:53
|
| To recapYou have to restore it then remove the files you don't want.You won't lose data. a feature of databases is they don't allow that.It won't allow you to drop a file unless all the data is migrated to other files.You can oly restore to the file structure of the original database. You can then merge files as above.==========================================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. |
 |
|
|
|