Views:

Applies To:

GroupID 8, 9 and 10 - Synchronize

Business Scenario:

We have multiple address fields in our source file and would like to populate the street address of the users in the directory in multiline format by combining the values from multiple address fields.

Desired address format:

12-H
6th Street
Red Coast
Venice

Solution:

GroupID Synchronize enables you to read data from a source, apply transformations, and populate it to a destination, such as a database or a directory.

Use a Synchronize job to take the address values from multiple fields in the source file and populate them in the Street Address field in multiline format for user/contact objects in a directory.

Steps:

  1. In GroupID Management Console, select Synchronize > All Jobs and then click New Job in the Actions pane.

  2. On the Select Source page of the New Job wizard, provide the source file and the required details.

  3. Go through the pages of the wizard until you reach the Field Mapping page.

  4. For Street Address, click the Transform button and then click Edit Script, as shown below:

  5. A script editor opens with all the source file fields listed on the left side. Copy the script provided below and modify the field names as needed.

    Dim s as String =""
    If (DTM.Source("House Number").Trim() <> "") Then
    s = s & DTM.Source("House Number").Trim()
    End If

    If (DTM.Source("Street").Trim() <> "") Then
    s = s & vbCrLf & DTM.Source("Street").Trim()
    End If

    If (DTM.Source("Area").Trim() <> "") Then
    s= s & vbCrLf & DTM.Source("Area").Trim()
    End If

    If (DTM.Source("City").Trim() <> "") Then
    s= s & vbCrLf & DTM.Source("City").Trim()
    End If

    DTM.Result = s

    In the script editor, the script should appear as:

  6. Once you have edited the script, click the check mark to test and then click OK to return to the New Job wizard.

  7. On the Completion page of the wizard, click the Preview job when finished check box if you would like to preview the job when you complete the wizard.

  8. Run the job to verify the results.

References:

  • GroupID Online Help - Synchronize > Creating a job
  • GroupID Online Help - Script Transformation