Script in SSIs-use the assembly in the script task

Source: Internet
Author: User
Tags ssis

 

COM and its successor. Net have a feature that can be repeatedly written in other languages.ProgramSet. In SQL Server 2005, only VB. NET can be used for script tasks. Here, we can use an assembly written in any. NET language.

Use the Assembly to reuse the already writtenCodeYou may have written the data verification method in your program. Now you can reuse the code in the package. Writing the tested code again is meaningless.

To use an assembly in your own code, you need to reference it first. We need to put the Assembly in an available path and ensure that the. NET Framework is installed on the machine where it is located.
Add an assembly in the Visual Studio editing environment. In the project menu, select Add reference, 1.

Figure 1

Select the assembly to be added from the list, and click OK to add the assembly to the project. In this way, all the methods in the Assembly can be used.


To delete an assembly, right-click the added assembly and right-click Remove.

We wrote a helloword package, which contains only one script task, which completes a simple task. Replace this program with an assembly, and use the program and implementation.

 

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.