July 17, 2017 at 6:46 am
Hi,
Can see some database files in the server drives. Is there anyway we can figure out which was the name of the original database the files used to be?
Thanks.
July 17, 2017 at 7:16 am
I've always used this to check physical files to current dbnames
select d.name, m.name, m.physical_name
from sys.master_files m
inner join sys.databases d
on (m.database_id = d.database_id)
order by 3,1, 2
This does not help you determine what an "orphaned" file used to belong to, especially if someone has changed that database name without changing the underlying physical names (happens around here all the time)
------------------------------------------------------------------------------------------------Standing in the gap between Consultant and ContractorKevin3NFDallasDBAs.com/BlogWhy is my SQL Log File HUGE?!?![/url]The future of the DBA role...[/url]SQL Security Model in Plain English[/url]
July 17, 2017 at 7:24 am
Thanks
Thanks.
Viewing 3 posts - 1 through 3 (of 3 total)
You must be logged in to reply to this topic. Login to reply