Showing posts with label mdf. Show all posts
Showing posts with label mdf. Show all posts

Friday, March 30, 2012

How to determine which file belongs to which filegroup and whichdatabase

Hi,
I am writing a C++ program that will take backup of .mdf files. I will
be provided with .mdf files. And for that mdf file, I need to know
the database name and file group name associated with this .mdf file.
How can I do it? Please help me to sort this out.
Thanks
Iftekhar
<chayancse@.gmail.com> wrote in message
news:3b6adb60-0322-4f4b-973b-a9fbee6dd0b0@.e10g2000prf.googlegroups.com...
> Hi,
> I am writing a C++ program that will take backup of .mdf files. I will
> be provided with .mdf files. And for that mdf file, I need to know
> the database name and file group name associated with this .mdf file.
> How can I do it? Please help me to sort this out.
> Thanks
> Iftekhar
You don't need that information to do backups because the BACKUP command
will take care of everything for you. Don't attempt to access or backup the
MDF/LDF files directly because you can't guarantee a good backup that way
without taking the database offline.
The information you are looking for is in these three system tables:
sys.database_files
sys.filegroups
sys.data_spaces
David Portas
|||On Feb 7, 12:18 pm, "David Portas"
<REMOVE_BEFORE_REPLYING_dpor...@.acm.org> wrote:
> <chayan...@.gmail.com> wrote in message
> news:3b6adb60-0322-4f4b-973b-a9fbee6dd0b0@.e10g2000prf.googlegroups.com...
>
>
> You don't need that information to do backups because the BACKUP command
> will take care of everything for you. Don't attempt to access or backup the
> MDF/LDF files directly because you can't guarantee a good backup that way
> without taking the database offline.
> The information you are looking for is in these three system tables:
> sys.database_files
> sys.filegroups
> sys.data_spaces
> --
> David Portas
Dear David,
Thanks for your reply. The system tables you have mentioned will help
me to determine the physical files associated with a database. But i
need to do the reverse task. I need to determine the logical database
name from a physical file name. Can you help me with this?
Also, is there any way to directly backup .mdf files without knowing
the database name?
Thanks
Iftekhar
|||Hi Iftekhar,
As David mentioned, a backup of the files of an online database is not a
valid backup.
Use the T-SQL BACKUP command instead.
Hope this helps,
Ben Nevarez
"chayancse@.gmail.com" wrote:

> On Feb 7, 12:18 pm, "David Portas"
> <REMOVE_BEFORE_REPLYING_dpor...@.acm.org> wrote:
> Dear David,
> Thanks for your reply. The system tables you have mentioned will help
> me to determine the physical files associated with a database. But i
> need to do the reverse task. I need to determine the logical database
> name from a physical file name. Can you help me with this?
> Also, is there any way to directly backup .mdf files without knowing
> the database name?
> Thanks
> Iftekhar
>
|||Hi

> I need to determine the logical database
> name from a physical file name. Can you help me with this?
It can be a problem. I have seen ( only one time) when the person rename the
physical file name and it was not associated with the name of database
<chayancse@.gmail.com> wrote in message
news:e2777758-af6e-4263-8f06-89c3fa692a33@.m34g2000hsb.googlegroups.com...
> On Feb 7, 12:18 pm, "David Portas"
> <REMOVE_BEFORE_REPLYING_dpor...@.acm.org> wrote:
> Dear David,
> Thanks for your reply. The system tables you have mentioned will help
> me to determine the physical files associated with a database. But i
> need to do the reverse task. I need to determine the logical database
> name from a physical file name. Can you help me with this?
> Also, is there any way to directly backup .mdf files without knowing
> the database name?
> Thanks
> Iftekhar
|||<chayancse@.gmail.com> wrote in message
news:e2777758-af6e-4263-8f06-89c3fa692a33@.m34g2000hsb.googlegroups.com...
> Dear David,
> Thanks for your reply. The system tables you have mentioned will help
> me to determine the physical files associated with a database. But i
> need to do the reverse task. I need to determine the logical database
> name from a physical file name. Can you help me with this?
> Also, is there any way to directly backup .mdf files without knowing
> the database name?
>
That doesn't make much sense to me. You should be backing up DATABASES not
FILES. Why would you want to backup a file without knowing what database it
belonged to?
Find the database name here:
SELECT
DB_NAME(database_id) database_name,
physical_name
FROM master.sys.master_files;
Now use BACKUP to backup the database. Don't attempt to backup the file. If
you don't understand the difference then please study the topics on Backup
and Restore in Books Online.
David Portas
|||On Feb 8, 1:30 am, "David Portas"
<REMOVE_BEFORE_REPLYING_dpor...@.acm.org> wrote:
> <chayan...@.gmail.com> wrote in message
> news:e2777758-af6e-4263-8f06-89c3fa692a33@.m34g2000hsb.googlegroups.com...
>
>
>
> That doesn't make much sense to me. You should be backing up DATABASES not
> FILES. Why would you want to backup a file without knowing what database it
> belonged to?
> Find the database name here:
> SELECT
> DB_NAME(database_id) database_name,
> physical_name
> FROM master.sys.master_files;
> Now use BACKUP to backup the database. Don't attempt to backup the file. If
> you don't understand the difference then please study the topics on Backup
> and Restore in Books Online.
> --
> David Portas
Thanks David. My task has been done. It's really unusual to backup
files instead of database. But I am developing a file backup system.
That will backup all normal files. If any of them are database files,
still they must be backed up.
Anyway, it's your post that actually helped me. So thanks a lot.
Thanks
Iftekhar

How to determine which file belongs to which filegroup and which

Hi,
I am writing a C++ program that will take backup of .mdf files. I will
be provided with .mdf files. And for that mdf file, I need to know
the database name and file group name associated with this .mdf file.
How can I do it? Please help me to sort this out.
Thanks
Iftekhar<chayancse@.gmail.com> wrote in message
news:3b6adb60-0322-4f4b-973b-a9fbee6dd0b0@.e10g2000prf.googlegroups.com...
> Hi,
> I am writing a C++ program that will take backup of .mdf files. I will
> be provided with .mdf files. And for that mdf file, I need to know
> the database name and file group name associated with this .mdf file.
> How can I do it? Please help me to sort this out.
> Thanks
> Iftekhar
You don't need that information to do backups because the BACKUP command
will take care of everything for you. Don't attempt to access or backup the
MDF/LDF files directly because you can't guarantee a good backup that way
without taking the database offline.
The information you are looking for is in these three system tables:
sys.database_files
sys.filegroups
sys.data_spaces
--
David Portas|||On Feb 7, 12:18 pm, "David Portas"
<REMOVE_BEFORE_REPLYING_dpor...@.acm.org> wrote:
> <chayan...@.gmail.com> wrote in message
> news:3b6adb60-0322-4f4b-973b-a9fbee6dd0b0@.e10g2000prf.googlegroups.com...
> > Hi,
> > I am writing a C++ program that will take backup of .mdf files. I will
> > be provided with .mdf files. And for that mdf file, I need to know
> > the database name and file group name associated with this .mdf file.
> > How can I do it? Please help me to sort this out.
> > Thanks
> > Iftekhar
> You don't need that information to do backups because the BACKUP command
> will take care of everything for you. Don't attempt to access or backup the
> MDF/LDF files directly because you can't guarantee a good backup that way
> without taking the database offline.
> The information you are looking for is in these three system tables:
> sys.database_files
> sys.filegroups
> sys.data_spaces
> --
> David Portas
Dear David,
Thanks for your reply. The system tables you have mentioned will help
me to determine the physical files associated with a database. But i
need to do the reverse task. I need to determine the logical database
name from a physical file name. Can you help me with this?
Also, is there any way to directly backup .mdf files without knowing
the database name?
Thanks
Iftekhar|||Hi Iftekhar,
As David mentioned, a backup of the files of an online database is not a
valid backup.
Use the T-SQL BACKUP command instead.
Hope this helps,
Ben Nevarez
"chayancse@.gmail.com" wrote:
> On Feb 7, 12:18 pm, "David Portas"
> <REMOVE_BEFORE_REPLYING_dpor...@.acm.org> wrote:
> > <chayan...@.gmail.com> wrote in message
> >
> > news:3b6adb60-0322-4f4b-973b-a9fbee6dd0b0@.e10g2000prf.googlegroups.com...
> >
> > > Hi,
> >
> > > I am writing a C++ program that will take backup of .mdf files. I will
> > > be provided with .mdf files. And for that mdf file, I need to know
> > > the database name and file group name associated with this .mdf file.
> >
> > > How can I do it? Please help me to sort this out.
> >
> > > Thanks
> > > Iftekhar
> >
> > You don't need that information to do backups because the BACKUP command
> > will take care of everything for you. Don't attempt to access or backup the
> > MDF/LDF files directly because you can't guarantee a good backup that way
> > without taking the database offline.
> >
> > The information you are looking for is in these three system tables:
> >
> > sys.database_files
> > sys.filegroups
> > sys.data_spaces
> >
> > --
> > David Portas
> Dear David,
> Thanks for your reply. The system tables you have mentioned will help
> me to determine the physical files associated with a database. But i
> need to do the reverse task. I need to determine the logical database
> name from a physical file name. Can you help me with this?
> Also, is there any way to directly backup .mdf files without knowing
> the database name?
> Thanks
> Iftekhar
>|||Hi
> I need to determine the logical database
> name from a physical file name. Can you help me with this?
It can be a problem. I have seen ( only one time) when the person rename the
physical file name and it was not associated with the name of database
<chayancse@.gmail.com> wrote in message
news:e2777758-af6e-4263-8f06-89c3fa692a33@.m34g2000hsb.googlegroups.com...
> On Feb 7, 12:18 pm, "David Portas"
> <REMOVE_BEFORE_REPLYING_dpor...@.acm.org> wrote:
>> <chayan...@.gmail.com> wrote in message
>> news:3b6adb60-0322-4f4b-973b-a9fbee6dd0b0@.e10g2000prf.googlegroups.com...
>> > Hi,
>> > I am writing a C++ program that will take backup of .mdf files. I will
>> > be provided with .mdf files. And for that mdf file, I need to know
>> > the database name and file group name associated with this .mdf file.
>> > How can I do it? Please help me to sort this out.
>> > Thanks
>> > Iftekhar
>> You don't need that information to do backups because the BACKUP command
>> will take care of everything for you. Don't attempt to access or backup
>> the
>> MDF/LDF files directly because you can't guarantee a good backup that way
>> without taking the database offline.
>> The information you are looking for is in these three system tables:
>> sys.database_files
>> sys.filegroups
>> sys.data_spaces
>> --
>> David Portas
> Dear David,
> Thanks for your reply. The system tables you have mentioned will help
> me to determine the physical files associated with a database. But i
> need to do the reverse task. I need to determine the logical database
> name from a physical file name. Can you help me with this?
> Also, is there any way to directly backup .mdf files without knowing
> the database name?
> Thanks
> Iftekhar|||<chayancse@.gmail.com> wrote in message
news:e2777758-af6e-4263-8f06-89c3fa692a33@.m34g2000hsb.googlegroups.com...
> Dear David,
> Thanks for your reply. The system tables you have mentioned will help
> me to determine the physical files associated with a database. But i
> need to do the reverse task. I need to determine the logical database
> name from a physical file name. Can you help me with this?
> Also, is there any way to directly backup .mdf files without knowing
> the database name?
>
That doesn't make much sense to me. You should be backing up DATABASES not
FILES. Why would you want to backup a file without knowing what database it
belonged to?
Find the database name here:
SELECT
DB_NAME(database_id) database_name,
physical_name
FROM master.sys.master_files;
Now use BACKUP to backup the database. Don't attempt to backup the file. If
you don't understand the difference then please study the topics on Backup
and Restore in Books Online.
--
David Portas|||On Feb 8, 1:30 am, "David Portas"
<REMOVE_BEFORE_REPLYING_dpor...@.acm.org> wrote:
> <chayan...@.gmail.com> wrote in message
> news:e2777758-af6e-4263-8f06-89c3fa692a33@.m34g2000hsb.googlegroups.com...
>
> > Dear David,
> > Thanks for your reply. The system tables you have mentioned will help
> > me to determine the physical files associated with a database. But i
> > need to do the reverse task. I need to determine the logical database
> > name from a physical file name. Can you help me with this?
> > Also, is there any way to directly backup .mdf files without knowing
> > the database name?
> That doesn't make much sense to me. You should be backing up DATABASES not
> FILES. Why would you want to backup a file without knowing what database it
> belonged to?
> Find the database name here:
> SELECT
> DB_NAME(database_id) database_name,
> physical_name
> FROM master.sys.master_files;
> Now use BACKUP to backup the database. Don't attempt to backup the file. If
> you don't understand the difference then please study the topics on Backup
> and Restore in Books Online.
> --
> David Portas
Thanks David. My task has been done. It's really unusual to backup
files instead of database. But I am developing a file backup system.
That will backup all normal files. If any of them are database files,
still they must be backed up.
Anyway, it's your post that actually helped me. So thanks a lot.
Thanks
Iftekhar

Monday, March 19, 2012

How to detect a dead database

I have a database of SqlServer call myData, and it's physicial is
c:\myData.mdf.
Some one stop the SQLServer Service, then delete c:\myData.mdf, then
start the SQLService, and then the database myData is dead.
How can I detect if myData is in this state?Ad
The sysdatabases table has a column status. Read the BOL about it
http://www.karaszi.com/SQLServer/in..._suspect_db.asp
"ad" <flying@.wfes.tcc.edu.tw> wrote in message
news:OqBggcyyGHA.4408@.TK2MSFTNGP05.phx.gbl...
>I have a database of SqlServer call myData, and it's physicial is
>c:\myData.mdf.
> Some one stop the SQLServer Service, then delete c:\myData.mdf, then
> start the SQLService, and then the database myData is dead.
> How can I detect if myData is in this state?
>|||If the physical file containing the database has been deleted, then the
database is truly gone.
Do you have a backup?
Arnie Rowland, Ph.D.
Westwood Consulting, Inc
Most good judgment comes from experience.
Most experience comes from bad judgment.
- Anonymous
"ad" <flying@.wfes.tcc.edu.tw> wrote in message
news:OqBggcyyGHA.4408@.TK2MSFTNGP05.phx.gbl...
>I have a database of SqlServer call myData, and it's physicial is
>c:\myData.mdf.
> Some one stop the SQLServer Service, then delete c:\myData.mdf, then
> start the SQLService, and then the database myData is dead.
> How can I detect if myData is in this state?
>|||> Some one stop the SQLServer Service, then delete c:\myData.mdf, then
> start the SQLService, and then the database myData is dead.
Did you hire a terrorist?
Just like the case of DBF in Foxpro, if you delete the table.dbf, there
is no way to recover it. You may wanna try Easy Data Recovery Pro to
undelete the file. Did you check the recycle bin?
Man-wai Chang
Softmedia Technology Co., Ltd.
Tel: (852)3583 2780|||I did not wnat to recover the database.
I want to confirm if the database has no physical file before delete it.
How can I confirm the database has no physical file?
"Man-wai Chang" <info@.softmedia.hk>
'?:OIcIYg0yGHA.4844@.TK2MSFTNGP04.phx.gbl...
> Did you hire a terrorist?
> Just like the case of DBF in Foxpro, if you delete the table.dbf, there is
> no way to recover it. You may wanna try Easy Data Recovery Pro to undelete
> the file. Did you check the recycle bin?
>
> --
> Man-wai Chang
> Softmedia Technology Co., Ltd.
> Tel: (852)3583 2780|||Hi,
As a first step ensure that no one have rights to SQL Server box apart from
authorised people. If you have backup you could
restore the database from Backup.
Thanks
Hari
SQL Server MVP
"ad" <flying@.wfes.tcc.edu.tw> wrote in message
news:OqBggcyyGHA.4408@.TK2MSFTNGP05.phx.gbl...
>I have a database of SqlServer call myData, and it's physicial is
>c:\myData.mdf.
> Some one stop the SQLServer Service, then delete c:\myData.mdf, then
> start the SQLService, and then the database myData is dead.
> How can I detect if myData is in this state?
>|||Hi,
Execute the command from Master database:-
DROP DATABASE <DBNAME>
This command will drop the database and close all physical MDF and LDF
Files.
Thanks
hari
SQL Server MVP
"ad" <flying@.wfes.tcc.edu.tw> wrote in message
news:ObiV0Q2yGHA.4116@.TK2MSFTNGP02.phx.gbl...
>I did not wnat to recover the database.
> I want to confirm if the database has no physical file before delete it.
> How can I confirm the database has no physical file?
>
> "Man-wai Chang" <info@.softmedia.hk>
> '?:OIcIYg0yGHA.4844@.TK2MSFTNGP04.phx.gbl...
>|||Thanks,
But how can I dertiminate if a database lost it's physicial file?
"Hari Prasad" <hari_prasad_k@.hotmail.com> glsD:ey1nz22yGHA.4204@.TK2MSFTNGP04.phx.g
bl...
> Hi,
> Execute the command from Master database:-
> DROP DATABASE <DBNAME>
> This command will drop the database and close all physical MDF and LDF
> Files.
> Thanks
> hari
> SQL Server MVP
>
> "ad" <flying@.wfes.tcc.edu.tw> wrote in message
> news:ObiV0Q2yGHA.4116@.TK2MSFTNGP02.phx.gbl...
>|||ad wrote:
> Thanks,
> But how can I dertiminate if a database lost it's physicial file?
>
If you're on SQL 2000, query the sysdatabases table to get the data file
name, then use xp_cmdshell or the undocumented xp_fileexists sproc to
see if the file exists.
Tracy McKibben
MCDBA
http://www.realsqlguy.com|||Hi,
Database will move to suspect status.
Thanks
Hari
SQL Server MVP
"ad" <flying@.wfes.tcc.edu.tw> wrote in message
news:%23uh5rS6yGHA.996@.TK2MSFTNGP03.phx.gbl...
> Thanks,
> But how can I dertiminate if a database lost it's physicial file?
>
> "Hari Prasad" <hari_prasad_k@.hotmail.com>
> glsD:ey1nz22yGHA.4204@.TK2MSFTNGP04.phx.gbl...
>

How to detect a dead database

I have a database of SqlServer call myData, and it's physicial is
c:\myData.mdf.
Some one stop the SQLServer Service, then delete c:\myData.mdf, then
start the SQLService, and then the database myData is dead.
How can I detect if myData is in this state?Ad
The sysdatabases table has a column status. Read the BOL about it
http://www.karaszi.com/SQLServer/info_corrupt_suspect_db.asp
"ad" <flying@.wfes.tcc.edu.tw> wrote in message
news:OqBggcyyGHA.4408@.TK2MSFTNGP05.phx.gbl...
>I have a database of SqlServer call myData, and it's physicial is
>c:\myData.mdf.
> Some one stop the SQLServer Service, then delete c:\myData.mdf, then
> start the SQLService, and then the database myData is dead.
> How can I detect if myData is in this state?
>|||If the physical file containing the database has been deleted, then the
database is truly gone.
Do you have a backup?
--
Arnie Rowland, Ph.D.
Westwood Consulting, Inc
Most good judgment comes from experience.
Most experience comes from bad judgment.
- Anonymous
"ad" <flying@.wfes.tcc.edu.tw> wrote in message
news:OqBggcyyGHA.4408@.TK2MSFTNGP05.phx.gbl...
>I have a database of SqlServer call myData, and it's physicial is
>c:\myData.mdf.
> Some one stop the SQLServer Service, then delete c:\myData.mdf, then
> start the SQLService, and then the database myData is dead.
> How can I detect if myData is in this state?
>|||> Some one stop the SQLServer Service, then delete c:\myData.mdf, then
> start the SQLService, and then the database myData is dead.
Did you hire a terrorist? :)
Just like the case of DBF in Foxpro, if you delete the table.dbf, there
is no way to recover it. You may wanna try Easy Data Recovery Pro to
undelete the file. Did you check the recycle bin?
Man-wai Chang
Softmedia Technology Co., Ltd.
Tel: (852)3583 2780|||I did not wnat to recover the database.
I want to confirm if the database has no physical file before delete it.
How can I confirm the database has no physical file?
"Man-wai Chang" <info@.softmedia.hk>
'?:OIcIYg0yGHA.4844@.TK2MSFTNGP04.phx.gbl...
>> Some one stop the SQLServer Service, then delete c:\myData.mdf, then
>> start the SQLService, and then the database myData is dead.
> Did you hire a terrorist? :)
> Just like the case of DBF in Foxpro, if you delete the table.dbf, there is
> no way to recover it. You may wanna try Easy Data Recovery Pro to undelete
> the file. Did you check the recycle bin?
>
> --
> Man-wai Chang
> Softmedia Technology Co., Ltd.
> Tel: (852)3583 2780|||Hi,
As a first step ensure that no one have rights to SQL Server box apart from
authorised people. If you have backup you could
restore the database from Backup.
Thanks
Hari
SQL Server MVP
"ad" <flying@.wfes.tcc.edu.tw> wrote in message
news:OqBggcyyGHA.4408@.TK2MSFTNGP05.phx.gbl...
>I have a database of SqlServer call myData, and it's physicial is
>c:\myData.mdf.
> Some one stop the SQLServer Service, then delete c:\myData.mdf, then
> start the SQLService, and then the database myData is dead.
> How can I detect if myData is in this state?
>|||Hi,
Execute the command from Master database:-
DROP DATABASE <DBNAME>
This command will drop the database and close all physical MDF and LDF
Files.
Thanks
hari
SQL Server MVP
"ad" <flying@.wfes.tcc.edu.tw> wrote in message
news:ObiV0Q2yGHA.4116@.TK2MSFTNGP02.phx.gbl...
>I did not wnat to recover the database.
> I want to confirm if the database has no physical file before delete it.
> How can I confirm the database has no physical file?
>
> "Man-wai Chang" <info@.softmedia.hk>
> '?:OIcIYg0yGHA.4844@.TK2MSFTNGP04.phx.gbl...
>> Some one stop the SQLServer Service, then delete c:\myData.mdf, then
>> start the SQLService, and then the database myData is dead.
>> Did you hire a terrorist? :)
>> Just like the case of DBF in Foxpro, if you delete the table.dbf, there
>> is no way to recover it. You may wanna try Easy Data Recovery Pro to
>> undelete the file. Did you check the recycle bin?
>>
>> --
>> Man-wai Chang
>> Softmedia Technology Co., Ltd.
>> Tel: (852)3583 2780
>|||Thanks,
But how can I dertiminate if a database lost it's physicial file?
"Hari Prasad" <hari_prasad_k@.hotmail.com> ¼¶¼g©ó¶l¥ó·s»D:ey1nz22yGHA.4204@.TK2MSFTNGP04.phx.gbl...
> Hi,
> Execute the command from Master database:-
> DROP DATABASE <DBNAME>
> This command will drop the database and close all physical MDF and LDF
> Files.
> Thanks
> hari
> SQL Server MVP
>
> "ad" <flying@.wfes.tcc.edu.tw> wrote in message
> news:ObiV0Q2yGHA.4116@.TK2MSFTNGP02.phx.gbl...
>>I did not wnat to recover the database.
>> I want to confirm if the database has no physical file before delete it.
>> How can I confirm the database has no physical file?
>>
>> "Man-wai Chang" <info@.softmedia.hk>
>> '?:OIcIYg0yGHA.4844@.TK2MSFTNGP04.phx.gbl...
>> Some one stop the SQLServer Service, then delete c:\myData.mdf, then
>> start the SQLService, and then the database myData is dead.
>> Did you hire a terrorist? :)
>> Just like the case of DBF in Foxpro, if you delete the table.dbf, there
>> is no way to recover it. You may wanna try Easy Data Recovery Pro to
>> undelete the file. Did you check the recycle bin?
>>
>> --
>> Man-wai Chang
>> Softmedia Technology Co., Ltd.
>> Tel: (852)3583 2780
>>
>|||ad wrote:
> Thanks,
> But how can I dertiminate if a database lost it's physicial file?
>
If you're on SQL 2000, query the sysdatabases table to get the data file
name, then use xp_cmdshell or the undocumented xp_fileexists sproc to
see if the file exists.
Tracy McKibben
MCDBA
http://www.realsqlguy.com|||Hi,
Database will move to suspect status.
Thanks
Hari
SQL Server MVP
"ad" <flying@.wfes.tcc.edu.tw> wrote in message
news:%23uh5rS6yGHA.996@.TK2MSFTNGP03.phx.gbl...
> Thanks,
> But how can I dertiminate if a database lost it's physicial file?
>
> "Hari Prasad" <hari_prasad_k@.hotmail.com>
> ¼¶¼g©ó¶l¥ó·s»D:ey1nz22yGHA.4204@.TK2MSFTNGP04.phx.gbl...
>> Hi,
>> Execute the command from Master database:-
>> DROP DATABASE <DBNAME>
>> This command will drop the database and close all physical MDF and LDF
>> Files.
>> Thanks
>> hari
>> SQL Server MVP
>>
>> "ad" <flying@.wfes.tcc.edu.tw> wrote in message
>> news:ObiV0Q2yGHA.4116@.TK2MSFTNGP02.phx.gbl...
>>I did not wnat to recover the database.
>> I want to confirm if the database has no physical file before delete it.
>> How can I confirm the database has no physical file?
>>
>> "Man-wai Chang" <info@.softmedia.hk>
>> '?:OIcIYg0yGHA.4844@.TK2MSFTNGP04.phx.gbl...
>> Some one stop the SQLServer Service, then delete c:\myData.mdf, then
>> start the SQLService, and then the database myData is dead.
>> Did you hire a terrorist? :)
>> Just like the case of DBF in Foxpro, if you delete the table.dbf, there
>> is no way to recover it. You may wanna try Easy Data Recovery Pro to
>> undelete the file. Did you check the recycle bin?
>>
>> --
>> Man-wai Chang
>> Softmedia Technology Co., Ltd.
>> Tel: (852)3583 2780
>>
>>
>