Skip to content

Latest commit

 

History

History
65 lines (44 loc) · 4.11 KB

multiple-files-connection-manager.md

File metadata and controls

65 lines (44 loc) · 4.11 KB
title description author ms.author ms.date ms.service ms.subservice ms.topic helpviewer_keywords
Multiple Files Connection Manager
Multiple Files Connection Manager
chugugrace
chugu
03/03/2017
sql
integration-services
conceptual
folders [Integration Services], connections
files [Integration Services], connections
Multiple Files connection manager
connection managers [Integration Services], Multiple Files
connections [Integration Services], files
multiple file connections

Multiple Files Connection Manager

[!INCLUDEsqlserver-ssis]

A Multiple Files connection manager enables a package to reference existing files and folders, or to create files and folders at run time.

Note

The built-in tasks and data flow components in [!INCLUDEssISnoversion] do not use the Multiple Files connection manager. However, you can use this connection manager in the Script task or Script component. For information about how to use connection managers in the Script task, see Connecting to Data Sources in the Script Task. For information about how to use connection managers in the Script component, see Connecting to Data Sources in the Script Component.

Usage Types of the Multiple Files Connection Manager

The FileUsageType property of the Multiple Files connection manager specifies how the connection is used. The Multiple Files connection manager can create files, create folders, use existing files, and use existing folders.

The following table lists the values of FileUsageType.

Value Description
0 Multiple Files connection manager uses an existing file.
1 Multiple Files connection manager creates a file.
2 Multiple Files connection manager uses an existing folder.
3 Multiple Files connection manager creates a folder.

Configuration of the Multiple Files Connection Manager

When you add a Multiple Files connection manager to a package, [!INCLUDEssISnoversion] creates a connection manager that will resolve to a Multiple Files connection at run time, sets the Multiple Files connection properties, and adds the Multiple Files connection to the Connections collection of the package.

The ConnectionManagerType property of the connection manager is set to MULTIFILE.

You can configure a Multiple Files connection manager in the following ways:

  • Specify the usage type of files and folders.

  • Specify files and folders.

  • If using multiple files or folders, specify the order in which the files and folders are accessed.

If the Multiple Files connection manager references multiple files and folders, the paths of the files and folders are separated by the pipe (|) character. The ConnectionString property of the connection manager has the following format:

<path>|<path>

You can also specify multiple files or folders using wildcard characters. For example, to reference all the text files on the C drive, the value of the ConnectionString property can be set to C:\*.txt.

You can set properties through [!INCLUDEssIS] Designer or programmatically.

For more information about the properties that you can set in [!INCLUDEssIS] Designer, see Add File Connection Manager Dialog Box UI Reference.

For information about configuring a connection manager programmatically, see xref:Microsoft.SqlServer.Dts.Runtime.ConnectionManager and Adding Connections Programmatically.