Quantcast
Channel: SQL Server Integration Services forum
Viewing all articles
Browse latest Browse all 24688

Building a data flow task, within a foreach loop for dynamic table name, but ole db source not allowing variable

$
0
0

In my control flow, I set up a variable for the table name, enumerated by SMO, following the instructions from the link here:
http://www.bidn.com/blogs/mikedavis/ssis/156/using-a-for-each-loop-on-tables-ssis

Now, I put a data flow task inside the foreach. I selected the OLE DB connection manger for my database, set the Data access mode to "Table name or view name variable", and selected my variable name from the drop down. So far so good. When I click on OK, it gives me an error 0x80040E37, basically saying it can't open the rowset for "my variable", Check that the object exists in the database.

So, I assume I won't be able to do this "that' easily, and I will need to build a "SQL command from variable" or some such thing. Any advice on how to build this Source editor to dynamically name my columns from the variable?

Thanks in advance!

mpleaf


Viewing all articles
Browse latest Browse all 24688

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>