File system

  • Hi All,

    I have a database with one .mdf, one .ndf file and one .ldf file.

    My database have approximate 200 tables.

    Here my question is:

    How can I find which file contains how many tables and what tables ?

    If I want to delete .ndf file without loosing the data, what procedure does I need to follow ?

    Thanks and Regrds!!

    Thank You.

    Regards,
    Raghavender Chavva

  • Raghavender (9/25/2009)


    Hi All,

    I have a database with one .mdf, one .ndf file and one .ldf file.

    My database have approximate 200 tables.

    Here my question is:

    How can I find which file contains how many tables and what tables ?

    If I want to delete .ndf file without loosing the data, what procedure does I need to follow ?

    Thanks and Regrds!!

    First off, you cannot find out what tables on in what file, that has already been discussed in another article. you might get somewhere if you are using partitions and multiple filegroups.

    For your other query, you can use dbcc shrinkfile with the emptyfile parameter

    --------------------------------------------------------------------------------------
    [highlight]Recommended Articles on How to help us help you and[/highlight]
    [highlight]solve commonly asked questions[/highlight]

    Forum Etiquette: How to post data/code on a forum to get the best help by Jeff Moden[/url]
    Managing Transaction Logs by Gail Shaw[/url]
    How to post Performance problems by Gail Shaw[/url]
    Help, my database is corrupt. Now what? by Gail Shaw[/url]

Viewing 2 posts - 1 through 1 (of 1 total)

You must be logged in to reply to this topic. Login to reply