Skip to content

Latest commit

 

History

History
38 lines (28 loc) · 1.86 KB

File metadata and controls

38 lines (28 loc) · 1.86 KB
title Saving a Package Programmatically
description Saving a Package Programmatically
author chugugrace
ms.author chugu
ms.date 03/14/2017
ms.service sql
ms.subservice integration-services
ms.topic reference
helpviewer_keywords
programmatically saving a package
saving a package programmatically

Saving a Package Programmatically

[!INCLUDEsqlserver-ssis]

After building a new package programmatically, or modifying an existing one, you usually want to save your changes.

All of the methods used in this topic to save packages require a reference to the Microsoft.SqlServer.ManagedDTS assembly. After you add the reference in a new project, import the xref:Microsoft.SqlServer.Dts.Runtime namespace with a using or Imports statement.

Saving a Package Programmatically

To save a package programmatically, call one of the following methods of the [!INCLUDEssISnoversion] xref:Microsoft.SqlServer.Dts.Runtime.Application class:

Storage Location Method to Call
File xref:Microsoft.SqlServer.Dts.Runtime.Application.SaveToXml%2A
SSIS Package Store xref:Microsoft.SqlServer.Dts.Runtime.Application.SaveToDtsServer%2A
[!INCLUDEssNoVersion] xref:Microsoft.SqlServer.Dts.Runtime.Application.SaveToSqlServer%2A

or

xref:Microsoft.SqlServer.Dts.Runtime.Application.SaveToSqlServerAs%2A

Important

The methods of the xref:Microsoft.SqlServer.Dts.Runtime.Application class for working with the SSIS Package Store only support "." or the server name for the local server. You cannot use "(local)" or "localhost".

See Also

Save Packages