简体   繁体   中英

How to pass data (located on user's local drive) to SSIS package run from C# client application?

I want do run an SSIS package from a C# client application. The package needs to import data from a user provided file which would reside on user's local drive or his network share. I do not want to run SSIS Package Programmatically on the Local Computer as it would require SSIS to be installed on user machines. Form what I read, a better approach is to run SSIS Package Programmatically on a Remote Computer (via a webservice which runs on the sql server and triggers the ssis package). The problem is that the remote package would execute in the remote server context (SQL server machine) and it will not have access to the user provided path. Is there a solution to that issue that would not involve creating a network location accessible both to the users and sql server machine?

Have the C# client application FTP the file to the server prior to executing the package. Or have the client application insert the data into a staging table on the database first. Or have the web service accept the data, and write it to a staging area.

SSIS doesn't include any functionality for streaming a file to a package as input, so you have to rely on a standard way of accessing the data.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM