Craig,
xp_getfiledetails
Quote:> Is there any way of validating the path for the database file before
> attempting to create the database.
Q. How can I get file information using SQL Server?
(v1.0 1999.05.04)
A. Using the undocumented xp_getfiledetails procedure :-
create table #info (
alt_name varchar(255) null,
size_in_bytes int null,
creation_date int null,
creation_time int null,
last_written_date int null,
last_written_time int null,
last_accessed_date int null,
last_accessed_time int null,
attributes int null
)
insert #info exec master..xp_getfiledetails 'C:\Directory\File.nam'
Neil Pike MVP/MCSE. Protech Computing Ltd
(Please post ALL replies to the newsgroup only unless indicated otherwise)
For SQL FAQ entries see
http://go.compuserve.com/sqlserver (library 1) - latest stuff is always here
www.ntfaq.com/sql.html
http://www.swynk.com/faq/sql/sqlserverfaq.asp