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

The SSIS File Sweeper Expand / Collapse
Author
Message
Posted Saturday, May 15, 2010 1:55 PM
SSC-Enthusiastic

SSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-Enthusiastic

Group: General Forum Members
Last Login: Tuesday, April 15, 2014 4:32 PM
Points: 180, Visits: 673
Comments posted to this topic are about the item The SSIS File Sweeper
Post #922530
Posted Monday, May 17, 2010 2:23 AM


Ten Centuries

Ten CenturiesTen CenturiesTen CenturiesTen CenturiesTen CenturiesTen CenturiesTen CenturiesTen Centuries

Group: General Forum Members
Last Login: Friday, March 28, 2014 5:06 AM
Points: 1,204, Visits: 915
Dear Mr Gonzalez,
Your article lack somewhat in explanation. You keep refering to "your example" and "if we used your example" but then you use variables that was not created in your article. The table you created has the following names:
filePath, pattern, daysToKeep, includeSubFolders
You created variables:
daysToKeep, fileMetaData, filePath, includeSubFolders, pattern
but all of a sudden you talk about a variable called FileName???? Maybe I am silly, stupid or just incompetent but now I do not know whether you meant filePath or should I create a variable "fileName". I am rather new in ssis but not in visual studio so I sort of find my way around and tried to do this but till I came to the scripting portion and Visual Studio give me an error. "File" is not defined. I am stumped. I do not know enough and would like to use ssis more often.


Manie Verster
Developer
Johannesburg
South Africa

I can do all things through Christ who strengthens me. - Holy Bible
I am a man of fixed and unbending principles, the first of which is to be flexible at all times. - Everett Mckinley Dirkson (Well, I am trying. - Manie Verster)
Post #922748
Posted Monday, May 17, 2010 2:38 AM


Ten Centuries

Ten CenturiesTen CenturiesTen CenturiesTen CenturiesTen CenturiesTen CenturiesTen CenturiesTen Centuries

Group: General Forum Members
Last Login: Friday, March 28, 2014 5:06 AM
Points: 1,204, Visits: 915
Mr.Gonzalez,

I apologize for the "File" part. I never saw the part where you said at the top we must add System .IO.


Manie Verster
Developer
Johannesburg
South Africa

I can do all things through Christ who strengthens me. - Holy Bible
I am a man of fixed and unbending principles, the first of which is to be flexible at all times. - Everett Mckinley Dirkson (Well, I am trying. - Manie Verster)
Post #922753
Posted Monday, May 17, 2010 10:35 AM
Grasshopper

GrasshopperGrasshopperGrasshopperGrasshopperGrasshopperGrasshopperGrasshopperGrasshopper

Group: General Forum Members
Last Login: Monday, April 23, 2012 12:59 PM
Points: 12, Visits: 165
Hello Mr. Gonzalez,

I am confused on how the properties Directory, FileSpec, Resource are assigned to variables...
based on my understanding the foreach loop container(Locate Files) has ADO enumerator and in this case the container will not show these propoerties...

Are there properties (Directory, FileSpec, Resource ) are assigned in the "Check for Delete" container?
If yes then what will be the enumerator and connection string in this container...

thanks for help on this.

Gaurav Mittal
Post #923002
Posted Monday, May 17, 2010 11:42 AM


SSC-Insane

SSC-InsaneSSC-InsaneSSC-InsaneSSC-InsaneSSC-InsaneSSC-InsaneSSC-InsaneSSC-InsaneSSC-InsaneSSC-InsaneSSC-Insane

Group: General Forum Members
Last Login: Yesterday @ 11:47 PM
Points: 20,458, Visits: 14,082
Thanks for sharing.



Jason AKA CirqueDeSQLeil
I have given a name to my pain...
MCM SQL Server


SQL RNNR

Posting Performance Based Questions - Gail Shaw
Posting Data Etiquette - Jeff Moden
Hidden RBAR - Jeff Moden
VLFs and the Tran Log - Kimberly Tripp
Post #923036
Posted Monday, May 17, 2010 11:57 AM
SSC Rookie

SSC RookieSSC RookieSSC RookieSSC RookieSSC RookieSSC RookieSSC RookieSSC Rookie

Group: General Forum Members
Last Login: Thursday, December 15, 2011 9:08 AM
Points: 34, Visits: 132
Gaurav,
He left out some important details about the inner loop. That one should be configured as a Foreach File Enumerator, not and ADO enumerator. The rest of the instructions will make more sense once you select the right enumerator. It's on the Collection tab of the Foreach Loop Editor.
HTH,
Jean
Post #923047
Posted Monday, May 17, 2010 12:26 PM
SSC-Enthusiastic

SSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-Enthusiastic

Group: General Forum Members
Last Login: Tuesday, April 15, 2014 4:32 PM
Points: 180, Visits: 673
jreece (5/17/2010)
Gaurav,
He left out some important details about the inner loop. That one should be configured as a Foreach File Enumerator, not and ADO enumerator. The rest of the instructions will make more sense once you select the right enumerator. It's on the Collection tab of the Foreach Loop Editor.
HTH,
Jean


I appears that I left that out. There are two foreach loops. One is to get the data that contains which folders you want to evaluate and the inner foreach loop does the actual deleting.
Post #923071
Posted Monday, May 17, 2010 12:44 PM
Grasshopper

GrasshopperGrasshopperGrasshopperGrasshopperGrasshopperGrasshopperGrasshopperGrasshopper

Group: General Forum Members
Last Login: Monday, April 23, 2012 12:59 PM
Points: 12, Visits: 165
Thanks All...this makes sense now.

Gaurav Mittal
Post #923084
Posted Monday, May 17, 2010 10:42 PM
Forum Newbie

Forum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum Newbie

Group: General Forum Members
Last Login: Tuesday, April 30, 2013 12:43 AM
Points: 6, Visits: 5
All of the others code should be put in a Try block. The Catch block at a minimum should contain the statement:

Dts.TaskResult = Dts.Results.Failure
Post #923286
Posted Tuesday, May 18, 2010 5:54 PM
Forum Newbie

Forum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum Newbie

Group: General Forum Members
Last Login: Wednesday, March 23, 2011 9:03 AM
Points: 1, Visits: 15
Has anyone seen any tool or code that will actually script out the ssis package?
Post #923993
« Prev Topic | Next Topic »

Add to briefcase

Permissions Expand / Collapse