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


Execute Process Task Arguments


Execute Process Task Arguments

Author
Message
Mordred
Mordred
SSChasing Mays
SSChasing Mays (642 reputation)SSChasing Mays (642 reputation)SSChasing Mays (642 reputation)SSChasing Mays (642 reputation)SSChasing Mays (642 reputation)SSChasing Mays (642 reputation)SSChasing Mays (642 reputation)SSChasing Mays (642 reputation)

Group: General Forum Members
Points: 642 Visits: 495
Hi all,

I currently am downloading zipped csv files from our source. As part of the process I am to have my package unzip the files but I'm unsure about the logic behind adding arguments to this process. For example, this link's second post describes creating variables to use as arguments but I'm not sure how to apply this logic to my own requirements. I have a variable called fileName which is used to change the names of all the zip files and its type is an Int32 that I parse into a string in my script task. I also have a variable "ExtractionFolder" (String) that holds the UNC path to where I want the unzipped files to be. I can give more information if needed about my variables but my only hold up now is the logic behind the arguments. I've been cruising msdn site to gain knowledge about this but I haven't found anything that describes how to set up the argument nor am I finding much information about arguments in general. I'm confused about this so if anyone can give me an explanation regarding arguments I would really appreciate it.

Regards:
Mordred
Keep on Coding in the Free World
Tatsu
Tatsu
SSCommitted
SSCommitted (1.6K reputation)SSCommitted (1.6K reputation)SSCommitted (1.6K reputation)SSCommitted (1.6K reputation)SSCommitted (1.6K reputation)SSCommitted (1.6K reputation)SSCommitted (1.6K reputation)SSCommitted (1.6K reputation)

Group: General Forum Members
Points: 1610 Visits: 307
Mordred (8/14/2012)
Hi all,

I currently am downloading zipped csv files from our source. As part of the process I am to have my package unzip the files but I'm unsure about the logic behind adding arguments to this process. For example, this link's second post describes creating variables to use as arguments but I'm not sure how to apply this logic to my own requirements. I have a variable called fileName which is used to change the names of all the zip files and its type is an Int32 that I parse into a string in my script task. I also have a variable "ExtractionFolder" (String) that holds the UNC path to where I want the unzipped files to be. I can give more information if needed about my variables but my only hold up now is the logic behind the arguments. I've been cruising msdn site to gain knowledge about this but I haven't found anything that describes how to set up the argument nor am I finding much information about arguments in general. I'm confused about this so if anyone can give me an explanation regarding arguments I would really appreciate it.


If you're not using SQL Server 2012 yet you might give TaskUnZip a try. I have not had a need to do this so I have not tried it myself.

If that's not an option, try this tutorial on calling 7-zip from the Execute Command task by Devendra Vagal.

I used the Execute Command task with gpg a while back to encrypt files for transmission. It took a little trial and error to figure things out but it all made sense in the end.

Be sure to let us know how you solve your problem so others can benefit!

Bryant E. Byrd, BSSE MCDBA MCAD
Business Intelligence Administrator
MSBI Administration Blog
Mordred
Mordred
SSChasing Mays
SSChasing Mays (642 reputation)SSChasing Mays (642 reputation)SSChasing Mays (642 reputation)SSChasing Mays (642 reputation)SSChasing Mays (642 reputation)SSChasing Mays (642 reputation)SSChasing Mays (642 reputation)SSChasing Mays (642 reputation)

Group: General Forum Members
Points: 642 Visits: 495
Thanks for the response! I have an unzip executable already in place but I am confused about the arguments I need to set in order to unzip the variable defined file as well as the the destination where the file should be unzipped to. There are examples on the interwebs but I find them convoluted as they are not very descriptive regarding how to set the paths in the arguments section. I'm still trying to figure this out and yes once I do I will post the solution.

Regards:
Mordred
Keep on Coding in the Free World
Mordred
Mordred
SSChasing Mays
SSChasing Mays (642 reputation)SSChasing Mays (642 reputation)SSChasing Mays (642 reputation)SSChasing Mays (642 reputation)SSChasing Mays (642 reputation)SSChasing Mays (642 reputation)SSChasing Mays (642 reputation)SSChasing Mays (642 reputation)

Group: General Forum Members
Points: 642 Visits: 495
After dragging my knuckles through the dirt I, with the help of a co-worker, have figured this out. Instead of placing the path to be unzipped in the Arguments section, I passed the path variable as an expression and left the Arguments empty. Now every zipped file passed into this process is unzipped successfully. Hopefully this makes sense.

Regards:
Mordred
Keep on Coding in the Free World
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