HOW SSIS package works when we try calling it from C# code ?

Hi,

I want to know whether I need to place the SSIS package in any sql server so that I can call it from C# CODE?
Can any one explain the process to call the ssis package code from C#

Thanks
Gowtham RamamoorthyAsked:
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

Anil GolamariCommented:
Hi,

Yes, you should be able place the package on the SQL Server and should be able to run the job using C# code. Below two links has some sample code for you.

https://msdn.microsoft.com/en-us/library/ms403355.aspx

http://www.codeproject.com/Tips/658959/Execute-SSIS-Packge-by-using-Csharp-and-SQL-Server
0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
Eugene ZCommented:
Note
"You cannot run packages outside BI Development Studio(sql2012+ SQL Server Data Tools ) on a client computer that does not have Integration Services installed, and the terms of your SQL Server licensing might not let you install Integration Services on additional computers. Integration Services is a server component and is not redistributable to client computers."

More:
Loading and Running a Remote Package Programmatically
https://msdn.microsoft.com/en-us/library/ms136090(v=sql.105).aspx

Running an SSIS Package Programmatically on a Remote Computer
https://msdn.microsoft.com/en-us/library/ms403355(v=sql.105).aspx
1
Gowtham RamamoorthyAuthor Commented:
Hi EugeneZ/lucky85,

Thanks for your comments. I will try with the above suggestions and code.

Can you please help me with the below questions

Many thanks in advance.
----------------------------------------------------------------------------------------------------------
I need to transform one single column values(columnA) from TABLE A in one database to another column B in TABLE B in some other database.

When i transfer columnA for example has (Employee names) but in the destination TABLE B it should be the (Employee ID). I have a lookup table which has the employeeID for the matching employee name.

Conditions:
I need only one single column gets updated in the destination TABLE B. without affecting any other columns.

I know this can be done in SSIS and i have created
* source oledb
*Lookup Transform
*Destination OLEDB

But the problem is at the destination output TABLE B the lookup transform is inserting NULL values to the unmatched column.

Can someone please guide me which is the best way to do this ?
Similarly  i need to include various flows for the destination table from various databases.
0
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Databases

From novice to tech pro — start learning today.

Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.