Using the Cmdlets
Start the PowerShell environment
To get started, simply open any Windows PowerShell IDE. The bcpToolkit
module now provides cmdlets that allow you to automate the work with BCP packages.
The module is generally imported automatically when you run one of its cmdlets.
Alternatively, you can open the bcpToolkit Console shortcut in the start menu, which executes Import-Module bcpToolkit
for you.
Open the package
Before you are able to work with your BCP package you have to open it in your PowerShell environment.
You can use our VaultBcp 2024
if you need a sample package.
Open the package by calling Open-BcpPackage. For now we ignore all the bomBlob*.xml files in the package.
Open-BcpPackage -Path 'C:\Temp\bcp_samplepackage' -IgnoreBomBlobs
Export the package
After the BCP package is loaded, we can export it to a new directory without links to the real files.
This allows importing the package on test environments, without the need for the source files at all.
Execute Export-BcpPackage with the arguments To and NoSourceFiles.
Export-BcpPackage -To 'C:\Temp\bcp_samplepackage_no_files\' -NoSourceFiles
Close the package
When we are done with the export, we can close the previously opened BCP package.
Running the cmdlet Close-BcpPackage will release all the memory resources.
Close-BcpPackage