SQL Clone
SQLServerCentral is supported by Redgate
 
Log in  ::  Register  ::  Not logged in
 
 
 


Moving files from one folder to another folder


Moving files from one folder to another folder

Author
Message
sqlstud
sqlstud
SSC-Enthusiastic
SSC-Enthusiastic (171 reputation)SSC-Enthusiastic (171 reputation)SSC-Enthusiastic (171 reputation)SSC-Enthusiastic (171 reputation)SSC-Enthusiastic (171 reputation)SSC-Enthusiastic (171 reputation)SSC-Enthusiastic (171 reputation)SSC-Enthusiastic (171 reputation)

Group: General Forum Members
Points: 171 Visits: 237
Hi,

I have one folder with two files

C:\Pkg\28052012_sample.xlsx

C:\Pkg\29052012_sample.xlsx

Using SSIS 2005 i have loaded the data from the above xlsx file using For each loop container.

Query:

Need to move the file to D:\Archive, after the package successfuly loaded the data.


Could you please let me know the steps?

Regards
Sqlstud
Regards

Sqlstud
Henrico Bekker
Henrico Bekker
Hall of Fame
Hall of Fame (3.7K reputation)Hall of Fame (3.7K reputation)Hall of Fame (3.7K reputation)Hall of Fame (3.7K reputation)Hall of Fame (3.7K reputation)Hall of Fame (3.7K reputation)Hall of Fame (3.7K reputation)Hall of Fame (3.7K reputation)

Group: General Forum Members
Points: 3704 Visits: 4371
I'd consider kicking of an executable batch job from ssis.

ref: http://ask.metafilter.com/50369/How-to-move-files-into-subdirectories-in-batch-job
John Mitchell-245523
John Mitchell-245523
SSChampion
SSChampion (14K reputation)SSChampion (14K reputation)SSChampion (14K reputation)SSChampion (14K reputation)SSChampion (14K reputation)SSChampion (14K reputation)SSChampion (14K reputation)SSChampion (14K reputation)

Group: General Forum Members
Points: 14434 Visits: 15980
Or you can use the File System Task built into SSIS.

John
sqlstud
sqlstud
SSC-Enthusiastic
SSC-Enthusiastic (171 reputation)SSC-Enthusiastic (171 reputation)SSC-Enthusiastic (171 reputation)SSC-Enthusiastic (171 reputation)SSC-Enthusiastic (171 reputation)SSC-Enthusiastic (171 reputation)SSC-Enthusiastic (171 reputation)SSC-Enthusiastic (171 reputation)

Group: General Forum Members
Points: 171 Visits: 237
sqlstud (10/16/2012)
Hi,

I have one folder with two files

C:\Pkg\28052012_sample.xlsx

C:\Pkg\29052012_sample.xlsx

Using SSIS 2005 i have loaded the data from the above xlsx file using For each loop container.

Query:

Need to move the file to D:\Archive, after the package successfuly loaded the data.


Could you please let me know the steps?

Regards
Sqlstud
Regards

Sqlstud







is it possible to rename the file after moved to destination folder

Regards
Sqlstud
John Mitchell-245523
John Mitchell-245523
SSChampion
SSChampion (14K reputation)SSChampion (14K reputation)SSChampion (14K reputation)SSChampion (14K reputation)SSChampion (14K reputation)SSChampion (14K reputation)SSChampion (14K reputation)SSChampion (14K reputation)

Group: General Forum Members
Points: 14434 Visits: 15980
I'll let you find that out for yourself. Just type "File System Task" into your favourite search engine.

John
sqlstud
sqlstud
SSC-Enthusiastic
SSC-Enthusiastic (171 reputation)SSC-Enthusiastic (171 reputation)SSC-Enthusiastic (171 reputation)SSC-Enthusiastic (171 reputation)SSC-Enthusiastic (171 reputation)SSC-Enthusiastic (171 reputation)SSC-Enthusiastic (171 reputation)SSC-Enthusiastic (171 reputation)

Group: General Forum Members
Points: 171 Visits: 237
sqlstud (10/16/2012)
Hi,

I have one folder with two files

C:\Pkg\28052012_sample.xlsx

C:\Pkg\29052012_sample.xlsx

Using SSIS 2005 i have loaded the data from the above xlsx file using For each loop container.

Query:

Need to move the file to D:\Archive, after the package successfuly loaded the data.


Could you please let me know the steps?

Regards
Sqlstud
Regards

Sqlstud






Thanks Henrico..

I need to move only after the successful loading.....
Go


Permissions

You can't post new topics.
You can't post topic replies.
You can't post new polls.
You can't post replies to polls.
You can't edit your own topics.
You can't delete your own topics.
You can't edit other topics.
You can't delete other topics.
You can't edit your own posts.
You can't edit other posts.
You can't delete your own posts.
You can't delete other posts.
You can't post events.
You can't edit your own events.
You can't edit other events.
You can't delete your own events.
You can't delete other events.
You can't send private messages.
You can't send emails.
You can read topics.
You can't vote in polls.
You can't upload attachments.
You can download attachments.
You can't post HTML code.
You can't edit HTML code.
You can't post IFCode.
You can't post JavaScript.
You can post emoticons.
You can't post or upload images.

Select a forum

































































































































































SQLServerCentral


Search