This tutorial guides you through the process of building your first data consolidation application.

You will load data from multiple operational systems into the hub for matching and merging. In this first unit, you will create a basic model with a simple match rule. Later, you will build on this foundation.

Learning outcomes

Learning track

This tutorial is the first unit of the Data Consolidation track.

In this tutorial, we assume that you already set up a working Semarchy xDM environment and that you have design-time privileges to connect to the Application Builder.

If you have not set up Semarchy xDM yet, refer to the Quick Install resources available in the Tutorials menu.

GO TO TUTORIALS

Additional setup information can also be found in the Semarchy xDM documentation.

Click on the button below to download the required resources, including the images and datasets used within this tutorial.

DOWNLOAD TUTORIAL RESOURCES

Semarchy xDM uses an entity-relationship diagram to help you create the logical model of your application.

Learning outcomes

Create a model

To get started, you need to create a new logical model. This model will contain all of the metadata for your entities, attributes, rules, forms, collections, and applications.

  1. On the Application Builder main page, click on New Model.

  1. Enter B2BTutorial in the Name field and click Finish.

  1. Right-click on Diagrams and select Add Diagram.

  1. Enter MainDiagram in the Name field and click Finish.

Add the Company entity

You are now ready to create the Company entity. At the end of the creation process, it should be configured as follows:

Attribute

Data type

Mandatory

Notes

ID

Sequence

Yes

Auto-numbered ID

CompanyName

String(128)

Yes

None

Website

String(128)

No

None

Region

List of values

No

Refers to RegionLOV

Address1

String(128)

No

None

PostalCode

String(128)

No

None

City

String(128)

No

None

State

String(128)

No

None

Country

List of values

No

Refers to CountryLOV

To add a new entity to your model, the fastest way is to add it to your diagram.

  1. From the Diagram editor, click Add Entity, and then click on the diagram itself.

  1. Enter the following values on the first page of the wizard, and then click Next.

  1. On the next page, enter the following values to configure the primary key of your entity:
  1. Click Finish.

Add a simple attribute

  1. In the Diagram editor, right-click on the Company entity, and then select Add Simple Attribute.

  1. Enter the following values:
  1. Click Finish.

  1. Click the Save all current content button on the top of the Model Design view to save your work.

Add lists of values

You are now going to add two new lists of values (LOV) that you will use for the Region and Country attributes.

Create the Region LOV

  1. Right-click on List of Values in the Model Design view and select Add List of Values.

  1. Enter RegionLOV in the Name field, then click Finish.
  2. Click the Add Value button to add the first value of your LOV.

  1. Enter APAC in the Code field and keep the auto-generated label unmodified.

  1. Do the same for the other values, as shown below.

Code

Label

EMEA

EMEA

North_America

North America

South_America

South America

  1. Click Save.

Add the Region attribute to the Company entity

We will now add to the Company entity the attribute that will use the Region LOV.

  1. Go back to the Main Diagram.
  2. Select the Main Diagram editor tab or double-click on Diagrams > Main Diagram in the Model Design view.

  1. Right-click on the Company entity and select Add Simple Attribute.

  1. Enter the following values:

  1. Click Finish.

Create the Country LOV

We will now create the CountryLOV list of values using an Excel file.

  1. Proceed as before to create this second LOV.

  1. Back to the List of Values editor, click the Import values button.
  2. Click the Browse button and select (or drag and drop) the data-consolidation\datasets\countries-lov.xlsx file from the tutorial resources you downloaded earlier.

  1. Click Finish.
  2. Review the imported values.

  1. Save your work.

Add the Country attribute to the Company entity

Add the Country simple attribute to your entity the same way you did for Region, using the following values:

Add the other attributes

It is now time to add the other attributes to your entity.

  1. Following the same instructions you used for CompanyName, add the following attributes to the Company entity:

Attribute

Datatype

Mandatory

Website

String(128)

No

Address1

String(128)

No

PostalCode

String(128)

No

City

String(128)

No

State

String(128)

No

  1. Return to the MainDiagram and click Show data types in the button bar to display the data types next to attribute names.
  2. Review your entity and check that all the required attributes have been added, as shown below.

  1. Save your work.

Assign an icon to the entity

It is a best practice to assign icons to your entities. These icons serve as visual guides across your application, enhancing user navigation.

  1. From the MainDiagram, click on the Company entity.
  2. In the Properties view below the editor, identify the Icon property within the Name and Description tab, and then click Select Image.

  1. Type domain in the search bar and press Enter to filter the images.
  2. Select the mdi/domain.svg image.

  1. Save your work.

Congratulations!

You have successfully created the main entity.

To summarize:

Next, you will add a second entity and link it with the Company entity.

You are now ready to create the Industry entity, as described below:

Attribute

Datatype

Mandatory

Notes

ID

String(20)

Yes

ID is set manually

Title

String(128)

Yes

Name of the Industry

ShortDescription

String(500)

No

Description of this industry in paragraph form

Industries in this model are reference data used to classify companies. Here you will use the top level of the NAICS industry classification standard.

Next, you will:

Create the Industry entity

To create the Industry entity, follow the same process as for the Company entity:

  1. Add the entity to the diagram with the following values and click Next:

  1. Configure the entity's primary key attribute on the next page:

  1. Add the Title and ShortDescription attributes as you did previously for the Company entity.

Attribute

Mandatory

Datatype

Description

Title

Yes

String(128)

Name of the Industry

ShortDescription

No

String(500)

Description of this industry in paragraph form

Assign an icon

Proceed the same way you did for Company to assign an icon for the Industry entity:

  1. From the MainDiagram, click on the Industry entity.
  2. In the Properties view, identify the Icon property within the Name and Description tab, and click Select Image.

  1. Type format-list-bulleted-type in the search bar to find and select mdi/format-list-bulleted-type.svg.

Create the Company-Industry reference

From the Main Diagram, create the reference relationship named CompaniesIndustry, from Company to Industry:

  1. Click Add Reference in the Palette.
  2. Click on the Company entity and drag the line to the Industry entity.

  1. Leave all values unmodified in the Create New Reference Relationship dialog, and then click Finish.

Congratulations!

You have successfully added another entity to your model and created a reference relationship.

To summarize:

Next, you will configure record matching and survivorship.

In this section, you will configure the match and survivorship rules that will apply to your application.

Learning outcomes

Matching data in Semarchy xDM

In Semarchy xDM, matching is performed on master records coming from source systems. It is a fundamental step of the certification process that aims at consolidating these master records into unique golden records.

In the case of fuzzy-matching entities (such as the Company entity you created previously), master and golden records use different identifiers:

Match rules define how incoming source records match together. You have full control of the rule details and the thresholds defining when matched records should merge and when merged records should be confirmed.

Once master records have been matched, survivorship rules define how their attributes will consolidate into the resulting golden record.

Create a match rule

It is now time to create your first match rule.

  1. In the Model Design view of the Application Builder, go to Entities > Company > Matcher.
  2. Right-click on Matcher and select Define SemQL Matcher.

  1. The description is optional. Click Finish.

  1. On the SemQL Matcher editor, click Add Match Rule.

  1. In the Name field, enter PerfectMatch.

  1. Scroll down the editor and identify the Match Condition field. Click Edit Expression.

  1. Copy and paste the following SemQL Condition in the SemQL editor, and then click OK.
Record1.CompanyName = Record2.CompanyName 
AND Record1.Address1 = Record2.Address1 
AND Record1.PostalCode = Record2.PostalCode 
AND Record1.Country = Record2.Country
  1. Click on SemQLMatcher - Company in the breadcrumb above the MatchRule editor to return to the SemQL Matcher editor.

  1. Scroll down to the Merge Policy section of the editor. Keep the default value for all thresholds. With this configuration, all matches will merge.

  1. Save your work.

Later, we will introduce nuances to handle fuzzy matches and match suggestions.

Add publishers

Publishers are applications that provide source data to the hub. They are commonly used in survivorship rules, but can also be used in match rules, enrichers, and in other locations in your model.

In this section, you will define four publishers: one for each source system that will submit data to xDM.

  1. Right-click on Publishers in the Model Design view and select Add Publisher.

  1. In the Name field, enter CRM.
  2. Keep the Publisher Code and Label fields unmodified, and then click Finish.

  1. Repeat the previous steps to create three other publishers:
  1. Save your work.

Configure a survivorship rule

It is time to set up your first survivorship rule. A default rule was created automatically with the entity. You will edit this rule to define the level of trust you place in each of your publishers.

  1. To configure the default survivorship rule, go to Entities > Company > Survivorship Rules in the Model Design view and double-click DefaultRule.

  1. Scroll down to the Consolidation Rule section.
  2. Set Consolidation Strategy to Preferred Publisher to select and order your publishers manually.

  1. Click the Select Publishers button next to the Preferred Publishers property.

You can use the Move Up or Move Down buttons to reorder the publishers.

  1. Click the Edit Expression button next to the Ranking Expression property.

  1. Enter the following SemQL expression to consolidate the value from the most recent record in case of a tie, and then click OK.
UpdateDate DESC

  1. Finally, set the Override Strategy property to Override - until next user change. With this configuration, changes by the data stewards are allowed and take precedence over the source systems:

  1. Save your work.

Congratulations!

You have successfully configured matching and survivorship rules.

To summarize:

Next, you will start to define the user experience for your application. You will learn how to add forms, collections, and more.

Semarchy xDM uses Material Design as the visual language for defining a business user interface. The user interface uses several application components that you will define later in this tutorial. These include display cards, forms, collections, steppers, search forms, action sets, business views, application actions, and more.

Learning outcomes

Application components

MDM applications in Semarchy xDM rely on several components that you can directly generate and configure in the Application Builder. The following examples are taken from the Product Retail Demo application.

Focus on display cards

Display cards define a visual representation of a record in a nicely formatted way. They can be used in collections or in fields to offer a compact view of this entity.

When generating application components, you will be prompted to define how you want your records to be displayed in display cards. You will define SemQL expressions that will translate into formatted text for your primary text and secondary text.

Here is how display cards will be configured for the Company and Industry entities:

Generate components

You will now use the Generate Application Components wizard to automatically generate most of the components you will need to enable user interaction with your data.

  1. In the Model Design view of the Application Builder, right-click on the Company entity under Entities and select Create Application Components.
  2. Keep all default settings and press Next.

  1. On the next page, observe that a default Primary Text Expression has been set: SEM_TO_CHAR2(ID).
    This expression returns the ID converted to a string.

  1. Set the Primary Text Expression.

  1. Set the Secondary Text Expression: follow the same procedure as for the Primary Text Expression and select the FDN_Industry attribute, or paste FDN_Industry into the text area.
  2. Click Finish.

  1. Repeat the instructions from step 1 for the Industry entity, using the following expressions for the display card:
  1. Save your work.

Explore the generated items

The wizard has generated all the required objects for the Company entity:

  1. Expand the Company entity to see all generated components.

  1. Scroll down in the Model Design view and go to Applications > DefaultApplication.

  1. Double-click on Folders and Actions and observe that a default list of menu items was initialized, including a BrowseCompany action.

Improve your application

In this section, you will improve your application before deploying it. You will:

Enable master data import

You are now going to configure the import action for the Company entity so that it supports importing master records instead of golden records, which is the default setting.

  1. Navigate to Entities > Company > Actions Sets and double-click on CompanyActionSet to open the editor for the generated action set.

  1. Select the ImportAuthorCompanies action in the Actions list. This opens the Properties inspector window below the editor.

  1. In the Name and Definition tab of the Properties view, set the Label property for this action to Import Master Records.

  1. Select the Action Configuration tab, and then set Imported Record Type to Master Records.

  1. Save the action set.

Customize golden data browsing

By default, an action was generated to browse golden records of the Company entity. You will customize the label and color of this action, and add a similar action for the master records.

  1. Navigate to Applications > DefaultApplication in the Model Design view and double-click on Folders and Actions.

  1. Select the BrowseCompany action.
  2. In the Name and Definition tab of the Properties view, set the Name of the action to BrowseCompanyGolden.

  1. Select the Display Properties tab and then set the following properties:

Enable master data browsing

To allow users to browse master records, you need to create a new action:

  1. In the Folders and Actions editor, click Add Action.

  1. Name your new action BrowseCompanyMaster, and then click Next.

  1. Configure the business view to browse as follows:
  1. Click Next.

  1. Configure the display properties as follows:

  1. Click on the new BrowseCompanyMaster action and set the Icon Color property to md:blue in the Display Properties tab of the Properties view.

  1. To customize the order of the actions in your menu, select the BrowseCompanyMaster action, and then click Move Up to move it above BrowseIndustry.

Configure the Global Search feature

The Global Search Configuration feature defines which business views are searched from the Global Search page, and how they are searched.

You will now configure the Global Search feature for both Company and Industry entities.

  1. Click on Global Search Configuration.
  2. In the Global Search Configuration editor, click Add Business View to Search above the Searched Business Views list.

  1. Enter the following values, and then click OK:

  1. Repeat the two previous steps to add Industry to the Global Search, using the following values:

  1. Save your work.

Brand your application

Now you will set some application properties to make things clear for your data stewards.

  1. Double-click Applications > DefaultApplication in the Model Design view.

  1. Configure the B2B Tutorial application by setting the following properties:

  1. Save your model.
  2. In the Model Design view, right-click on the root node B2BTutorial [0.0] and select Validate.
    No error or warning should be reported.

Congratulations!

You have successfully configured your first application.

To summarize:

Next, you will learn how to deploy this application and access it for the first time.

Semarchy xDM allows you to deploy your model to a data location. It will create all the physical tables and columns in a relational database (PostgreSQL, Oracle, or SQL Server), and generate the user interface of your application.

Learning outcomes

Create a datasource

Before creating a data location and deploying your model, you must create a platform datasource to connect to the SEMARCHY_EMP_TUTORIAL database schema that was created in the Quick Install tutorials.

  1. In the Application Builder toolbar, expand the user menu, and then select Welcome page.

  1. Select Configuration.

  1. Scroll down to the Connections section and click Datasources.

  1. Click the Add datasource floating action button.

  1. Enter the following values:
  1. Click Create.

  1. Enter the following connection parameters in the editor:

  1. Enter the password of the database schema:

  1. Click Test this Datasource in the button bar above the editor.

  1. A "Datasource test successful" message should be displayed. Click OK.

If another message is displayed, identify the error and fix the connection parameters.

  1. Click the Save and apply datasource modification button on the datasource editor.

  1. Open the user menu on the top-right corner and then select All applications to go back to the Welcome page.

Create the data location and deploy the application

In this section, you will create the B2BTutorial data location and deploy your model to this data location.

  1. Click the Management button in the Application Builder bar to access the Management perspective.

  1. Right-click on Data Locations and select New Data Location.

  1. Enter the following values, and then click Finish:

  1. Wait until deployment completes.

Connect to the application

In this section, you will connect to the application that you just deployed.

  1. In the Application Builder toolbar, expand the user menu, and then select Welcome page.

  1. From the Welcome page, click the B2B Tutorial application icon.

  1. If you have not yet completed the profile for the semadmin user in a previous tutorial, the following pop-up appears. Click Continue.

  1. Enter the following information for semadmin:
  1. Click Continue.

  1. On the next screen, click Get started.
  2. Discover the user interface which was built for your application:

  1. Click Companies (Golden) in the navigation drawer. Your application does not include any customers yet. You will fix that soon.

Congratulations!

You have successfully deployed and tested your first application.

To summarize:

Next, you will learn how to use this application to start loading data and browsing the results.

Now that you have deployed your model and application, it is time to load data.

While we use spreadsheets here, in a data consolidation hub, integration occurs via REST APIs or SQL. You will have the opportunity to explore realistic data integration in subsequent tutorials.

Semarchy xDM generates code for importing data from spreadsheets, match and merge records, and perform value survivorship.

Additional insights on application usage are available in the Customer B2C demo tutorial that illustrates a fully functional customer data application.

User profile

As a first-time user, you should update your profile information and preferences.

  1. In the B2B Tutorial application, open the user menu on the upper-right corner, and select Profile from the menu.

  1. Basic information about yourself is already set. Move your mouse over the default profile picture and click on the Change profile picture button.

  1. Select on your hard drive the semadmin.jpg picture which is available under the data-consolidation/pictures folder of the tutorial resources you downloaded previously.
  2. Click Upload.

  1. (Optional) Customize your user preferences like date format, language, etc. (Settings tab) and your login or role (Advanced tab)
  2. Click Save.

Import industries

In this section, you will import Industry reference data values from an excel spreadsheet.

  1. In the B2B Tutorial application, click on Industries in the navigation drawer, and then select Import from the actions menu.

  2. Select the data-consolidation\datasets\industries-data.xlsx file from the tutorials resources that you downloaded.
  3. Review the import contents and then click Continue.

  1. On the Define mappings screen, keep the default mappings and click Continue.

  1. Review the import summary and then click Finish to import the data.

  1. Review the imported data and click Finish. This submits the data to the certification process so that all users will have access to it.

Wait until the toaster in the bottom-left corner of the screen indicates "Changes successfully applied," and then click on Click to refresh to see the imported data.

Import companies

Repeat the previous steps to import companies.

  1. Click on Companies (Master) in the navigation drawer and select Import Master Records from the actions menu.

  1. Select the data-consolidation\datasets\companies-data.xlsx file from the tutorials resources you downloaded.
  2. Review the import contents and then click Continue.

  1. Click Continue on the next screen to confirm the mapping.
  2. Click Finish on the Import Summary page.

  1. Review the imported data and then click Finish.

  1. When the toaster indicates "Changes successfully applied," click on Click to refresh to see the imported master data.
    Note that 95 master records have been imported.

  1. Click on Companies (Golden) in the navigation drawer to see the golden data created from the master records. Observe that 74 golden records were created (compared to the 95 master records), which means that some records matched and merged. In the next tutorial unit, you will refine the match rules.

Use the Global Search feature

The Global Search feature allows you to search for records across multiple entities. In this tutorial, we configured the Global Search to search both industry and company data.

  1. Click on Global Search in the navigation drawer to access the feature.
  2. Type health in the Search text field and click the Search button.

  1. The application finds companies and industries which use the word health in their names.

  1. Search for chevron. Currently, xDM finds many Chevron records because the source records fail to match with your PerfectMatch rule. You will improve this soon!

Congratulations!

You have successfully used the application, loaded, and searched data.

Great job! You have built your first data consolidation application.

Learning recap

Next steps

In the next unit of the Data Consolidation tutorial track, Standardize, match, and merge, you will learn how to write custom match rules for your specific data requirements.

GO TO TUTORIALS

Thank you for completing this tutorial.