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


Variable As OLE DB Connection.


Variable As OLE DB Connection.

Author
Message
rocky_498
rocky_498
SSC-Addicted
SSC-Addicted (457 reputation)SSC-Addicted (457 reputation)SSC-Addicted (457 reputation)SSC-Addicted (457 reputation)SSC-Addicted (457 reputation)SSC-Addicted (457 reputation)SSC-Addicted (457 reputation)SSC-Addicted (457 reputation)

Group: General Forum Members
Points: 457 Visits: 1381
Hi Guys,

Need Help,I want to know what is the best way to deal this kinda Problem or approach.

I am creating almost 30 SSIS Packages, some of them or simple and some of them are really tough (SCD and Other Transformations),
First I am gonna run SSIS Packages on Test Server then Dev Server and then Finally Production.
Its to much for me to every time change OLE DB Connection, and recreate SCD mapping and everything.

I want to know If I can use OLEDB Connection as a VARIABLE, Instead of change all OLEDB Connection, just change one VARIABLE.
If I create Variable as a CONNECTIONString, I am having a error something like " It must consist of one or more components of the
form X = Y, separated by semicolons."

Any Help would be great appreciate or any other easy solution.

Thank You.
herladygeekedness
herladygeekedness
Mr or Mrs. 500
Mr or Mrs. 500 (518 reputation)Mr or Mrs. 500 (518 reputation)Mr or Mrs. 500 (518 reputation)Mr or Mrs. 500 (518 reputation)Mr or Mrs. 500 (518 reputation)Mr or Mrs. 500 (518 reputation)Mr or Mrs. 500 (518 reputation)Mr or Mrs. 500 (518 reputation)

Group: General Forum Members
Points: 518 Visits: 813
If I understand you correctly, Yes, we do this.

I have a local connection variable that resolves this way using expression

Data Source=YOURSERVER;Initial Catalog=YOURDATABASE;Provider=SQLNCLI.1;Integrated Security=SSPI;PacketSize=32767

Expression
"Data Source=" + @[User::cfgDWServerName] + ";Initial Catalog=" + @[User::cfgDWDatabaseName] + ";Provider=SQLNCLI.1;Integrated Security=SSPI;PacketSize=32767"


YOURSERVER and YOURDATABASE are the cfgDWServerName, cfgDWDatabaseName variables that I use configurations to set. So it's an easy move from dev to prod or sales or demo or whatever, I just use Set Variables tab in the job step to point to correct server/database.

There are many ways to do configurations and I only know this way so hope you can adapt for the method you use.

In dev, all I do is check variables to see that my connection is dev.

Hope this helps!
Koen Verbeeck
Koen Verbeeck
One Orange Chip
One Orange Chip (27K reputation)One Orange Chip (27K reputation)One Orange Chip (27K reputation)One Orange Chip (27K reputation)One Orange Chip (27K reputation)One Orange Chip (27K reputation)One Orange Chip (27K reputation)One Orange Chip (27K reputation)

Group: General Forum Members
Points: 27929 Visits: 13268
rocky_498 (4/4/2014)
Hi Guys,

Need Help,I want to know what is the best way to deal this kinda Problem or approach.

I am creating almost 30 SSIS Packages, some of them or simple and some of them are really tough (SCD and Other Transformations),
First I am gonna run SSIS Packages on Test Server then Dev Server and then Finally Production.
Its to much for me to every time change OLE DB Connection, and recreate SCD mapping and everything.

I want to know If I can use OLEDB Connection as a VARIABLE, Instead of change all OLEDB Connection, just change one VARIABLE.
If I create Variable as a CONNECTIONString, I am having a error something like " It must consist of one or more components of the
form X = Y, separated by semicolons."

Any Help would be great appreciate or any other easy solution.

Thank You.


The proper way of doing this is using configurations:

Understanding Integration Services Package Configurations


How to post forum questions.
Need an answer? No, you need a question.
What’s the deal with Excel & SSIS?
My blog at SQLKover.

MCSE Business Intelligence - Microsoft Data Platform MVP
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