DTSPackageType Enumerazione

Definizione

Identifica lo strumento che ha creato il pacchetto.

public enum class DTSPackageType
public enum DTSPackageType
type DTSPackageType = 
Public Enum DTSPackageType
Ereditarietà
DTSPackageType

Campi

Default 0

Non definito.

DTSDesigner 2

Specifica che il pacchetto è stato creato nella finestra di progettazione in SQL Server 2000.

DTSDesigner100 5

Specifica che il pacchetto è stato creato in SSIS Designer in SQL Server 2008 Integration Services (SSIS).

DTSWizard 1

Specifica che il pacchetto è stato creato utilizzando l'Importazione/Esportazione guidata SQL Server.

SQLDBMaint 6

Specifica che il client DBMaint ha creato il pacchetto.

SQLReplication 3

Specifica che il pacchetto è stato generato per supportare sottoscrizioni trasformabili.

Esempio

Nell'esempio di codice seguente viene caricato uno degli esempi di pacchetti di Integration Services e viene visualizzato il tipo di pacchetto, uno dei valori di questa enumerazione.

using System;  
using System.Collections.Generic;  
using System.Text;  
using Microsoft.SqlServer.Dts.Runtime;  

namespace Microsoft.SqlServer.SSIS.Samples  
{  
    class Program  
    {  
        static void Main(string[] args)  
        {  
            Application app = new Application();  
            Package pkg= new Package();  
            pkg = app.LoadPackage(@"C:\Program Files\Microsoft SQL Server\100\Samples\Integration Services\Package Samples\SmoTablesDBCC\SmoTablesDBCC\SmoTablesDBCC.dtsx", null);  

            // Display the package type.  
            Console.WriteLine("The package type is: {0}", pkg.PackageType);  
        }  
    }  
}  
Imports System  
Imports System.Collections.Generic  
Imports System.Text  
Imports Microsoft.SqlServer.Dts.Runtime  

Namespace Microsoft.SqlServer.SSIS.Samples  
    Class Program  
        Shared  Sub Main(ByVal args() As String)  
            Dim app As Application =  New Application()   
            Dim pkg As Package =  New Package()   
            pkg = app.LoadPackage("C:\Program Files\Microsoft SQL Server\100\Samples\Integration Services\Package Samples\SmoTablesDBCC\SmoTablesDBCC\SmoTablesDBCC.dtsx", Nothing)  

            ' Display the package type.  
            Console.WriteLine("The package type is: {0}", pkg.PackageType)  
        End Sub  
    End Class  
End Namespace  

Esempio di output

Il tipo di pacchetto è: DTSDesigner100

Si applica a