Please start any new threads on our new
site at https://forums.sqlteam.com. We've got lots of great SQL Server
experts to answer whatever question you can come up with.
| Author |
Topic |
|
AskSQLTeam
Ask SQLTeam Question
0 Posts |
Posted - 2001-09-06 : 09:17:27
|
| Mohammed writes "Hello SqlServer7 SP2Microsoft NTserver I want to monitor a file directory on Nt4 and as soon as some files appear I want to examin their date time stamps and then send an email.I have managed to get SQLMail to work so that I can send an email. I have found a stored procedure to see if a file exists and another to examine attributes (xp_getfiledetails). However I do not know how to use wild cards or search for all files in the directory and then examine each file.DECLARE @retcode intEXEC @retcode = sp_MSexists_file 'C:\MSSQL7\BINN\', 'g.txt'IF @retcode = 1PRINT 'File Exist'ELSEPRINT 'File does not Exist'I need to read you articles on SQLMail, as I am not sure if this is the best way to send an email.regards Mohammed" |
|
|
|
|
|