January 27, 2010 at 8:13 am
Adam.Massey (1/27/2010)
I am using 7-zip so does that mean e still means extract and o still means overwrite or is it different?
I am not sure i have not use 7-zip but it should be similar
January 27, 2010 at 8:44 am
Again my apologies...but like I said before, I am new to this environment and not familiar with SSIS...But for the foreach loop container when creating a variable as you mentioned...I clicked on the variable mapping tab and clicked the drop down to add a new variable...A pop up box came up with Specify the properties of the variable:
Container: It has Package as the default or do I change it to Foreach Loop Container
Name: Is this just whatever I call the variable?
Namespace: Not sure what this means?
Value Type: It has String as default, do I change this?
Value: It is left blank so what type of information do I type in this box?
Again Thank you so much for your help!
January 27, 2010 at 11:04 am
It's been a while since I've used 7-ZIP but I beleive one of the parameters available is an "unzip all from here down" type of parameter. 7-Zip comes with some "help" documentation... you can find it there. I just don't know it off the top of my head and I'm not using it in my current job.
--Jeff Moden
Change is inevitable... Change for the better is not.
January 27, 2010 at 1:32 pm
Alrighty lets forget about the Unzipping of the files for a moment...
Lets move to using SSIS to load data into a db...
Ok heres the problem...
I have a folder containing 24 .DBF and 10 .FPT files. I went by that link that steveb provided for me about creating a foreach loop to load the data into a db...
Here's the catch:
When I run just the data flow process it creates one table and it has 840 records in it...
When I created the package and included the foreach container and placed my data flow process inside...my end result was one table with 20160 rows...NOT RIGHT!!!
It loaded the same data into the same table 24x...
What did I do wrong...There were supposed to be 24 different tables with each table's data in it????
I think the problem is here:
During the data flow process, in my source - I have connected to the folder that contains the tables (.DBF files), I have data access mode set to table or view and then for name of the table or the view, i click the drop down and it has the 24 tables...BUT I can only select one...
Here is what I am wanting to happen:
I want it create the table and load the data that it has in it...I then want the loop to take the next table and create it and load that data...That is my what I want my end result to be...What do I need to do to get to that result????
January 28, 2010 at 8:11 am
Any Suggestions?????
Thanks in advance!
January 28, 2010 at 8:28 am
if you use the same source and destination in the loop then it will add them to the same table.
If you need to read and write to different tables then you need to make the connection strings dynamic (which is an advantage of SSIS almost everything can be set dynamically)
in the connection manager window-- select your data source and then press F4 to bring up the properties window.
In there you will find a row called expression that has a + next to it.
Expand this row and select the connection string property and create an expression for this.
This expression should include your FileName variable that the for-each loop passes to the data flows. This will resolve to valid connection string at run-time and will change on each iteration of the loop.
It may take a bit of trial and error but the easiest wasy to start is to copy the exsiting connection string from the properies and modfy this to include your filename parameter.
You will need to do something similar for the destination.
you may want to spend a little time reading about expressions in SSIS as they are useful for most dynamic processes.
This is from memory though as I dont have access to SSIS today to test them, but the steps should be close to what i have outlined.
Viewing 6 posts - 16 through 20 (of 20 total)
You must be logged in to reply to this topic. Login to reply