Results 1 to 2 of 2
  1. #1
    Join Date
    Sep 2003
    Posts
    22

    Unanswered: How to remove a file [dbcc shrinkfile('filename',empty) is not working]

    I tried to remove a file from a filegroup by using the following two comamnd
    1) dbcc SHRINKFILE('FileName1', EMPTYFILE)
    2) ALTER DATABASE PED_PROD REMOVE FILE FileName1

    but I am getting the following error message

    Server: Msg 5042, Level 16, State 1, Line 1
    The file ''FileName1'' cannot be removed because it is not empty.

    Please help in this

    Thanks in Advance,
    Sateesh

  2. #2
    Join Date
    May 2003
    Location
    UK
    Posts
    220
    Howdy

    What version of SQL are you using?

    Cheers

    SG

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •