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


Dynamic connections in SSIS


Dynamic connections in SSIS

Author
Message
adam_pearson
adam_pearson
Forum Newbie
Forum Newbie (3 reputation)Forum Newbie (3 reputation)Forum Newbie (3 reputation)Forum Newbie (3 reputation)Forum Newbie (3 reputation)Forum Newbie (3 reputation)Forum Newbie (3 reputation)Forum Newbie (3 reputation)

Group: General Forum Members
Points: 3 Visits: 380
Ignore that comment Kenneth! Reason for no results was due to SQL Express not listing anything in sys.master_files so failing the query (and one of the engineers dropping ther other test machine I was using off the domain)! Will look into getting the dynamic part of this working now.

thanks again!
Adam
Kenneth Fisher
Kenneth Fisher
SSCertifiable
SSCertifiable (6.3K reputation)SSCertifiable (6.3K reputation)SSCertifiable (6.3K reputation)SSCertifiable (6.3K reputation)SSCertifiable (6.3K reputation)SSCertifiable (6.3K reputation)SSCertifiable (6.3K reputation)SSCertifiable (6.3K reputation)

Group: General Forum Members
Points: 6267 Visits: 2059
adam_pearson (11/5/2012)
Hi Kenneth,
Thanks for the example however no joy with that either. Using either a table as the source or hard coding it into the FOREACH container doesn't appear to work. When it executes it runs without problems however only returns the results from the local machine. The servername changes to the ones in the list (using a message box) however when putting items into a table (using the @@servername for example) it's only the location machine being picked up.

I've tried setting the 'delayValidation' setting on and off but still no joy. Tried connecting to different servers but that hasn't helped either.

Any suggestions?

Thanks,
Adam


Just to confirm. You are using a FOR EACH loop, not a FOR loop. You have a variable mapped (under the variable mapping tab of the FOR EACH loop container) to store the output of the loop. You have an expression set up on the connection manager that you want to be changing and it uses the variable that you mapped in the FOR EACH loop. And last but not least is the code that you expect to have pointing to the new server inside the loop container?

If all that is true then see if you can walk through the setup on paper and post it to me. I would go ahead and use a Foreach Item Enumerator until you get it working since it has less moving parts to go wrong. Once we have that working then we can work on the next part.

Kenneth FisherI strive to live in a world where a chicken can cross the road without being questioned about its motives.--------------------------------------------------------------------------------For better, quicker answers on T-SQL questions, click on the following... http://www.sqlservercentral.com/articles/Best+Practices/61537/For better answers on performance questions, click on the following... http://www.sqlservercentral.com/articles/SQLServerCentral/66909/Link to my Blog Post --> www.SQLStudies.com
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