Solved

SSIS expression - Check when a file has been modified

Posted on 2008-06-20
2
202 Views
Last Modified: 2013-11-30
Hi,

In SSIS, how can you write an expression that checks if a file got modified today?

Thank you.
0
Comment
Question by:Endelm
2 Comments
 
LVL 13

Accepted Solution

by:
rickchild earned 500 total points
ID: 21831606
You can use a Script Task to do this using the "File.GetLastWriteTime" method.

You can make the script task write the result to a package variable.

Something like:  File.GetLastWriteTime("C:\Test1.txt").ToString()

http://msdn.microsoft.com/en-us/library/system.io.file.getlastwritetime.aspx
0
 

Author Closing Comment

by:Endelm
ID: 31469130
Thank you! :-)
0

Featured Post

Backup Your Microsoft Windows Server®

Backup all your Microsoft Windows Server – on-premises, in remote locations, in private and hybrid clouds. Your entire Windows Server will be backed up in one easy step with patented, block-level disk imaging. We achieve RTOs (recovery time objectives) as low as 15 seconds.

Join & Write a Comment

Suggested Solutions

Everyone has problem when going to load data into Data warehouse (EDW). They all need to confirm that data quality is good but they don't no how to proceed. Microsoft has provided new task within SSIS 2008 called "Data Profiler Task". It solve th…
Ever needed a SQL 2008 Database replicated/mirrored/log shipped on another server but you can't take the downtime inflicted by initial snapshot or disconnect while T-logs are restored or mirror applied? You can use SQL Server Initialize from Backup…
Using examples as well as descriptions, and references to Books Online, show the documentation available for date manipulation functions and by using a select few of these functions, show how date based data can be manipulated with these functions.
Viewers will learn how to use the SELECT statement in SQL to return specific rows and columns, with various degrees of sorting and limits in place.

760 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

20 Experts available now in Live!

Get 1:1 Help Now