Was this page helpful?
Your feedback about this content is important. Let us know what you think.
Additional feedback?
1500 characters remaining
Export (0) Print
Expand All

DacServices.Extract Method (String, String, String, Version, String, IEnumerable<Tuple<String, String>>, DacExtractOptions, Nullable<CancellationToken>)

Extracts the schema from a database into a package.

Namespace:  Microsoft.SqlServer.Dac
Assembly:  Microsoft.SqlServer.Dac (in Microsoft.SqlServer.Dac.dll)

public void Extract(
	string packageFileName,
	string databaseName,
	string applicationName,
	Version applicationVersion,
	string applicationDescription,
	IEnumerable<Tuple<string, string>> tables,
	DacExtractOptions extractOptions,
	Nullable<CancellationToken> cancellationToken
)

Parameters

packageFileName
Type: String
The path to the package file to be created.
databaseName
Type: String
The name of the source database.
applicationName
Type: String
The string identifier for the DAC application.
applicationVersion
Type: Version
The version of the DAC application.
applicationDescription
Type: String
The optional string summary of the DAC application.
tables
Type: IEnumerable<Tuple<String, String>>
The optional enumerable used to retrieve enumerator over set of tables for which reference data should be stored. For each Tuple in the enumeration the first item specifies the schema of the table, and the second specifies the base identifier of the table. If the value for this parameter is a null reference, no reference data will be stored.
extractOptions
Type: Microsoft.SqlServer.Dac.DacExtractOptions
The optional DacExtractOptions instance used to specify options that affect the behavior of package extraction.
cancellationToken
Type: Nullable<CancellationToken>
The optional CancellationToken that can be used to indicate that the operation should be cancelled. Use of this object does not guarantee that the operation will be cancelled.

ExceptionCondition
ArgumentException

If applicationName is a null reference or empty string.

DacServicesException

If a problem occurs during package extraction.

OperationCanceledException

If the CancellationToken has a cancellation requested and the operation could be cancelled.

Community Additions

Show:
© 2015 Microsoft