Exporting and importing views

You can export an out-of-the-box view or a custom view as a package file. The package file can then be imported and installed in the product. The file extension for the package file is .viewpkg.

If you export and import the custom view that uses a data mart, that data mart is also exported and imported. For details, see Data mart considerations.

With this feature, you can complete the following use cases:

  • Create a copy of a view: Export an out-of-the-box view, import it with a new name, modify its configuration, and save it as a new view. 
  • Migrate a view: Create a custom view in the development or test environment and after confirming that the results are accurate, import it in the production environment.
  • Share a view: Import a custom view that is created in one environment into a different destination environment.

You can export and import views by using the BMC Helix Continuous Optimization console or the APIs. For details, see the following sections:

To export and import views by using the BMC Helix Continuous Optimization console

Perform the following steps to export or import a view by using the BMC Helix Continuous Optimization console.

To export a view

  1. In the navigation pane of Views tab, select Manage Views. By default, the Views tab is displayed. 
  2. From the action menu that is located next to the view you want to export, click Export view
    The view is exported and you can select the location to save the exported view. The view is exported as the <View_Name>_<timestamp>.viewpkg file. 

To import a view

  1. If you are importing an out-of-the-box view, first install the view.
  2. In the navigation pane of Views tab, select Manage Views
  3. Click Import view. The Import view dialog box is displayed. 
  4. Click Browse to select the view package file (.viewpkg) that you want to import. 
  5. Click Apply
    message indicating the data mart creation or update is displayed. You can choose to Proceed or Cancel the import. If the destination environment already contains the view with the same name, a backup of the existing view is created. 
    The view is imported and listed in the Views table. 

To export and import views by using the APIs 

You can call the following endpoints of the Data Provider API to export and import views. For more information about accessing the API endpoints, see Continuous Optimization REST API endpoints.

APIUse to

Retrieve a list of all capacity views in BMC Helix Continuous Optimization.

GET/opt/api/v1/viewdefinition/view/{viewid}/exportExport the configuration of the selected view to a package file (.viewpkg).

Import a capacity view from another environment.

The request includes the name of the export file in the format: <view name_date of export>.viewpkg.

Data mart considerations

When you export and import the custom view, if the view is using a data mart, that data mart is also exported and then imported. If this data mart is using any data marts or being used in other data marts, all these data marts, that is, the entire hierarchy tree gets exported and and then imported in the destination environment. 

If your destination environment does not contain data marts that are being exported as part of the view package, they will be created. If the destination environment already contains the same data marts, they will be updated. If your destination environment includes any data marts with the same identifier as one of the data marts being imported, the existing data marts are updated by the imported data marts.

Consider that you have exported the VMware view that contains the VMware systems data mart with identifier as ER_V_VMWARE_SYS. This data mart has a related data mart as VMware hosts.

The destination environment contains the VMware VMs data mart with the identifier as ER_V_VMWARE_SYS.

After you import, the the VMware systems data mart overwrites the VMware VMs data mart as both have same identifiers. The related data mart, VMware hosts is linked to the VMware systems data mart.

In the following diagram, red text indicates data mart names and blue text indicates identifiers. 

Was this page helpful? Yes No Submitting... Thank you