Skip to main content
Matrix42 Self-Service Help Center

Adding custom attributes delivered from FireScope into ESM configuration items

Overview

If the SDDM Import data provider delivers also custom attributes that have been set for configuration items in FireScope, by default they will not be mapped to the attributes in Enterprise Service Management. However, you can configure the system so that such custom attributes are mapped to the required attributes in ESM.

For each type of the configuration item with custom attributes, you need to create a separate import definition which will map the custom attributes to ESM attributes.

Step by step guide to creating an import definition for custom attributes

In this example we will map the VM Host custom attribute to the Description attribute of the Computer CI.

SDDMStagingCI.png

SDDMStagingCIcustomValue.png

Starting with an import definition

To create an import definition:

  1. Open the Administration application and navigate to Integration > Import > Import Definition.
  2. Run the Create New Import Definition action. A wizard open.
  3. Select Computer as the type of object you want to import and click Data Source Definition.

The Specify data source details page

  1. On the Specify Data Source Details page, fill in the following data:
  • Choose MS SQL in the Source Type drop down.
  • Enter the ESM SQL Server in the Server field.
  • Enter M42Production in the Database field.
  • Select the Integrated Security checkbox.

SDDMCreateImpDef.png

  1. Click Additional Settings and then Table Source Definition.

The Define the structure of your source tables page

  1. Select SQL Expression as the central table setting.
  2. In the Expression field, enter EXEC [dbo].[CUSTPSO_SddmGetCustValues]

This is a stored procedure that is provided with the SDDM Import add-on.

  1. Click Preview. As a result, you will see all fetched custom attributes under Result Preview.
  2. Enter the following SQL statement into the Expression field:
select * from (
select
       sa.ObjectId as 'Object ID Asset'
      ,[CUSTPSO_Value]
      ,[CUSTPSO_Name]
         
 
  FROM [dbo].[CUSTPSO_SPSSddmStagingClassCustom] cc
  inner join dbo.CUSTPSO_SPSSddmStagingClassBase cb on cb.UsedInTypeCUSTPSO_SPSSddmStagingType = cc.UsedInTypeCUSTPSO_SPSSddmStagingType
  inner join SPSAssetClassBase sa on cb.CUSTPSO_relatedAsset = sa.ID
) x
 
pivot
 
(max(CUSTPSO_Value) for CUSTPSO_Name in ([<CUST VALUE NAME 1>],[<CUST VALUE NAME 2>])) p
  1. Adjust the [<CUST VALUE NAME 1>],[<CUST VALUE NAME 2>] part to include the required custom attributes. For example, [VM Host].

 This statement can also be used for printer and network device configuration items.

  1. Click Preview to see the results. You will see only objects that have the VM Host value filled in.SDDMCreateImpDefExpression.png
  2. Click Mapping Rule Settings to proceed.

The Mapping rules page

  1. On the Mapping Rules page click the add button.
  2. On the Define Source Column page that opens, fill in the following data:
  • Select Object ID Asset in the Source Column drop-down field.
  • Select SPSAssetClassBase in the Destination Data Definition field.
  • Choose ObjectId in the Destination Attribute field.
  • Select the Use this column to match criteria to the destination type checkbox.
  • Click Finish to add this mapping rule.

SDDMCreateImpDefMapping.png

  1. Click the add button again to add another mapping rule. 
  2. On the Define Source Column page that opens, fill in the following data:
  • Select VM Host in the Source Column drop-down field.
  • Select SPSAssetClassBase in the Destination Data Definition field.
  • Choose Description in the Destination Attribute field
  • Click Finish to add this mapping rule.
  1. Click Matching Query to proceed to the next page. This page allows to review the matching query.
  2. Click Import Action Definition.
  3. Clear the Insert checkbox under Specify import actions which should occur for the whole CI and all mapped multifragment data definitions.
  4. Click Import Summary Definition to proceed.

The Summary of the import definition page

  1. Provide the name for your import definition.
  2. Click Save and then Execute to make sure the import definition works correctly.

Once the import definition finishes, you can see the result log in the Progress field.

SDDMCreateImpDefExecute.png

Checking the updated attribute

You can check if the custom attribute has been updated correctly by opening the related endpoint device of the Staging CI in the Assets applicaion.

SDDMCustomAttrResult.png