Skip to content

Latest commit

 

History

History
86 lines (62 loc) · 4.62 KB

File metadata and controls

86 lines (62 loc) · 4.62 KB
title Managing Packages and Folders Programmatically
description Managing Packages and Folders Programmatically
author chugugrace
ms.author chugu
ms.date 03/14/2017
ms.service sql
ms.subservice integration-services
ms.topic reference
helpviewer_keywords
enumerators [Integration Services]
packages [Integration Services], managing
custom enumerators [Integration Services]

Managing Packages and Folders Programmatically

[!INCLUDEsqlserver-ssis]

As you work programmatically with [!INCLUDEssISnoversion] packages, you may want to determine whether an individual package or folder exists, or to manage the folders in which packages are stored. The xref:Microsoft.SqlServer.Dts.Runtime.Application class of the xref:Microsoft.SqlServer.Dts.Runtime namespace provides a variety of methods to satisfy these requirements.

Determining Whether a Package or Folder Exists

To determine programmatically whether a saved package exists, call one of the following methods before attempting to load and run the package:

Storage Location Method to Call
SSIS Package Store xref:Microsoft.SqlServer.Dts.Runtime.Application.ExistsOnDtsServer%2A
[!INCLUDEssNoVersion] xref:Microsoft.SqlServer.Dts.Runtime.Application.ExistsOnSqlServer%2A

To determine programmatically whether a folder exists, call one of the following methods before attempting to list the packages stored in the folder, :

Storage Location Method to Call
SSIS Package Store xref:Microsoft.SqlServer.Dts.Runtime.Application.FolderExistsOnDtsServer%2A
[!INCLUDEssNoVersion] xref:Microsoft.SqlServer.Dts.Runtime.Application.FolderExistsOnSqlServer%2A

Back to top

Managing Packages and Folders

The xref:Microsoft.SqlServer.Dts.Runtime.Application class of the xref:Microsoft.SqlServer.Dts.Runtime namespace provides additional methods for managing packages and the folders in which they are stored.

Removing a Package

To remove a saved package programmatically, call one of the following methods:

Storage Location Method to Call
SSIS Package Store xref:Microsoft.SqlServer.Dts.Runtime.Application.RemoveFromDtsServer%2A
[!INCLUDEssNoVersion] xref:Microsoft.SqlServer.Dts.Runtime.Application.RemoveFromSqlServer%2A

Back to top

Creating a Folder

To create a storage folder programmatically, call one of the following methods:

Storage Location Method to Call
SSIS Package Store xref:Microsoft.SqlServer.Dts.Runtime.Application.CreateFolderOnDtsServer%2A
[!INCLUDEssNoVersion] xref:Microsoft.SqlServer.Dts.Runtime.Application.CreateFolderOnSqlServer%2A

Back to top

Removing a Folder

To remove a storage folder programmatically, call one of the following methods:

Storage Location Method to Call
SSIS Package Store xref:Microsoft.SqlServer.Dts.Runtime.Application.RemoveFolderFromDtsServer%2A
[!INCLUDEssNoVersion] xref:Microsoft.SqlServer.Dts.Runtime.Application.RemoveFolderFromSqlServer%2A

Back to top

Renaming a Folder

To rename a storage folder programmatically, call one of the following methods:

Storage Location Method to Call
SSIS Package Store xref:Microsoft.SqlServer.Dts.Runtime.Application.RenameFolderOnDtsServer%2A
[!INCLUDEssNoVersion] xref:Microsoft.SqlServer.Dts.Runtime.Application.RenameFolderOnSqlServer%2A

Back to top

See Also

Package Management (SSIS Service)
Enumerating Available Packages Programmatically