다음을 통해 공유


Import-VamtData

Import-VamtData

Imports the data from a specified .cilx or .cil file into a VAMT database.

Syntax

Parameter Set: File
Import-VamtData [-InputFile] <String> [-DbCommandTimeout <Int32> ] [-DbConnectionString <String> ] [ <CommonParameters>]

Parameter Set: Products
Import-VamtData [-Products] <Product[]> [-DbCommandTimeout <Int32> ] [-DbConnectionString <String> ] [ <CommonParameters>]

Detailed Description

The Import-VamtData cmdlet imports data from a specified .cilx or .cil file into a database. You can merge data from a previous version of into your database by exporting the data in the previous version to a .cil file and then importing the .cil file into the database. You can import data from a .cilx file to recover data from a backup file.

Parameters

-DbCommandTimeout<Int32>

Indicates how long waits for a response from the database before timing out. The default value is 30 seconds. You can use the DbCommandTimeout parameter to change the timeout value.

Aliases

none

Required?

false

Position?

named

Default Value

none

Accept Pipeline Input?

true (ByPropertyName)

Accept Wildcard Characters?

false

-DbConnectionString<String>

Specifies the database that the data from the .cilx file or .cil file is imported into. If no database connection string is provided, attempts to use the database that the user console used on the local computer. If does not find a database, it returns an error. You can find the connection string in the UI in the Preferences dialog box. On the menu bar, click View, and then click Preferences to open the Volume Activation Management Tool Preferences dialog box. The connection string is in the Database Settings section under Current connection string.

Aliases

none

Required?

false

Position?

named

Default Value

none

Accept Pipeline Input?

true (ByPropertyName)

Accept Wildcard Characters?

false

-InputFile<String>

Specifies the name of the file that contains the data to import into the database. You cannot use the InputFile parameter together with the Products parameter.

Aliases

none

Required?

true

Position?

1

Default Value

none

Accept Pipeline Input?

true (ByValue, ByPropertyName)

Accept Wildcard Characters?

false

-Products<Product[]>

Specifies the product information to import. If the Products parameter is not included, all product information in the .cilx or .cil file is imported into the database. You cannot use the Products parameter together with the InputFile parameter.

Aliases

none

Required?

true

Position?

1

Default Value

none

Accept Pipeline Input?

true (ByValue, ByPropertyName)

Accept Wildcard Characters?

false

<CommonParameters>

This cmdlet supports the common parameters: -Verbose, -Debug, -ErrorAction, -ErrorVariable, -OutBuffer, and -OutVariable. For more information, see    about_CommonParameters (https://go.microsoft.com/fwlink/p/?LinkID=113216).

Examples

Example 1

This command imports data from the specified file.

PS C:\> import-vamtdata -inputfile .\vamtdata.cilx

Example 2

This command gets a product object, acquires the confirmation IDs for the products, and then imports the data to the database. Just acquiring the CIDs does not mean that the data is in the database. The data must be imported as shown in this example.

PS C:\> $productinfo = get-vamtproduct
PS C:\> $updatedproductinfo = get-vamtconfirmationid -products $productinfo
PS C:\> import-vamtdata -products $updatedproductinfo

Export-VamtData

Initialize-VamtData