Click here to monitor SSC
SQLServerCentral is supported by Red Gate Software Ltd.
 
Log in  ::  Register  ::  Not logged in
 
 
 
        
Home       Members    Calendar    Who's On


Add to briefcase 12»»

Check Files existence in a folder Expand / Collapse
Author
Message
Posted Tuesday, November 2, 2010 1:03 AM
Valued Member

Valued MemberValued MemberValued MemberValued MemberValued MemberValued MemberValued MemberValued Member

Group: General Forum Members
Last Login: Tuesday, February 10, 2015 10:00 PM
Points: 60, Visits: 238
Hi All,

how to implement the below req in SSIS:

how to find out whether any file is present in the specified folder.

Note: we dont know about the file name. Just we need to check whether any files present or not.

Thanks in Advance.
Post #1014303
Posted Tuesday, November 2, 2010 2:51 AM


Ten Centuries

Ten CenturiesTen CenturiesTen CenturiesTen CenturiesTen CenturiesTen CenturiesTen CenturiesTen Centuries

Group: General Forum Members
Last Login: Sunday, February 8, 2015 12:50 PM
Points: 1,047, Visits: 1,864
It depends, largely.

Please google WQL


Regards/Raunak
Now a member of Linkedin

Please visit the all new Performance Point Forum
Please visit the all new Data Mining and Business Analytics Forum
Post #1014328
Posted Tuesday, November 2, 2010 3:05 AM


SSCertifiable

SSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiable

Group: General Forum Members
Last Login: Today @ 6:22 AM
Points: 5,524, Visits: 12,880
Depends on what you will do next.

You might just be able to use a Foreach loop and put your 'file(s) found' processing inside it.



Help us to help you. For better, quicker and more-focused answers to your questions, consider following the advice in this link.

When you ask a question (and please do ask a question: "My T-SQL does not work" just doesn't cut it), please provide enough information for us to understand its context.

I had some words with my wife, and she had some paragraphs with me.
Post #1014331
Posted Tuesday, November 2, 2010 3:54 AM


SSCommitted

SSCommittedSSCommittedSSCommittedSSCommittedSSCommittedSSCommittedSSCommittedSSCommitted

Group: General Forum Members
Last Login: Friday, August 1, 2014 6:18 AM
Points: 1,618, Visits: 20,980
You may find xp_fileexists extended stored procedure useful. More information on this XP here

Pradeep Adiga
Blog: sqldbadiaries.com
Twitter: @pradeepadiga
Post #1014344
Posted Tuesday, November 2, 2010 4:01 AM
SSCrazy

SSCrazySSCrazySSCrazySSCrazySSCrazySSCrazySSCrazySSCrazy

Group: General Forum Members
Last Login: Tuesday, February 17, 2015 9:53 PM
Points: 2,808, Visits: 7,188
as another suggestion; the way we do it is to use a script task with the File.Exists Method

http://msdn.microsoft.com/en-us/library/system.io.file.exists.aspx
Post #1014346
Posted Tuesday, November 2, 2010 4:02 AM


Ten Centuries

Ten CenturiesTen CenturiesTen CenturiesTen CenturiesTen CenturiesTen CenturiesTen CenturiesTen Centuries

Group: General Forum Members
Last Login: Sunday, February 8, 2015 12:50 PM
Points: 1,047, Visits: 1,864
Adiga (11/2/2010)
You may find xp_fileexists extended stored procedure useful. More information on this XP here


The OP says, file name not known


Regards/Raunak
Now a member of Linkedin

Please visit the all new Performance Point Forum
Please visit the all new Data Mining and Business Analytics Forum
Post #1014349
Posted Tuesday, November 2, 2010 4:06 AM


Ten Centuries

Ten CenturiesTen CenturiesTen CenturiesTen CenturiesTen CenturiesTen CenturiesTen CenturiesTen Centuries

Group: General Forum Members
Last Login: Sunday, February 8, 2015 12:50 PM
Points: 1,047, Visits: 1,864
One of the suitable approach would be to watch the said directory using a FileSystemWatcher and fire appropriate events as associated. This seems doable as the system does not deems necessary for a filename to be known.

Regards/Raunak
Now a member of Linkedin

Please visit the all new Performance Point Forum
Please visit the all new Data Mining and Business Analytics Forum
Post #1014351
Posted Tuesday, November 2, 2010 4:30 AM


Ten Centuries

Ten CenturiesTen CenturiesTen CenturiesTen CenturiesTen CenturiesTen CenturiesTen CenturiesTen Centuries

Group: General Forum Members
Last Login: 2 days ago @ 10:16 PM
Points: 1,175, Visits: 774
Hi,

Use Script Task go to design script
U can write C# or VB Script for the same

Cheers!
Sasidhar Pulivarthi
Post #1014356
Posted Tuesday, November 2, 2010 4:32 AM


SSCertifiable

SSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiable

Group: General Forum Members
Last Login: Today @ 6:22 AM
Points: 5,524, Visits: 12,880
Pulivarthi Sasidhar (11/2/2010)
Hi,

Use Script Task go to design script
U can write C# or VB Script for the same

Cheers!
Sasidhar Pulivarthi


What does this give the OP that Steveb's post did not?



Help us to help you. For better, quicker and more-focused answers to your questions, consider following the advice in this link.

When you ask a question (and please do ask a question: "My T-SQL does not work" just doesn't cut it), please provide enough information for us to understand its context.

I had some words with my wife, and she had some paragraphs with me.
Post #1014359
Posted Tuesday, November 2, 2010 4:38 AM


Ten Centuries

Ten CenturiesTen CenturiesTen CenturiesTen CenturiesTen CenturiesTen CenturiesTen CenturiesTen Centuries

Group: General Forum Members
Last Login: Sunday, February 8, 2015 12:50 PM
Points: 1,047, Visits: 1,864
Phil Parkin (11/2/2010)
Pulivarthi Sasidhar (11/2/2010)
Hi,

Use Script Task go to design script
U can write C# or VB Script for the same

Cheers!
Sasidhar Pulivarthi


What does this give the OP that Steveb's post did not?


In any case, File.Exists() cannot be used


Regards/Raunak
Now a member of Linkedin

Please visit the all new Performance Point Forum
Please visit the all new Data Mining and Business Analytics Forum
Post #1014360
« Prev Topic | Next Topic »

Add to briefcase 12»»

Permissions Expand / Collapse