Associating the Metadata Definitions

To associate and synchronize objects and their metadata between different vaults, the metadata definitions must also be associatable between different vaults.

Associations between metadata definitions can be made in several ways depending on how the vaults are used. Certain metadata definitions are always associated automatically. Some of them are associated automatically according to the vault structure, but for some of them, it must be done manually using aliases.

Purpose of the Vault vs. Metadata Associations

Associations between metadata can be created in several ways, depending on the purpose of use of the vaults. The target vault can be used in archiving, replication, backups, and publication. For this reason, you should consider – before creating a vault that might be used as a target vault – which implementation is the easiest and best for creation of the desired vault.

If the association and synchronization is performed between two or more existing vaults, check the association of the metadata definitions and define the scheduled export and import between vaults.

Perfect copy (for example replication, archiving, and backup)

If you want the vaults to be perfect – full and complete – copies of each other in terms of both metadata and contents, you should first create a target vault through backup or copy of the relevant vault and then define the export and import. This way, especially the metadata definitions are automatically matched with the names and IDs and any separate definition of aliases need not be performed one metadata definition at a time.

Note: Metadata definitions created after creation of the vault must be manually associated between vaults by using aliases.

Partially the same metadata structure and partially the same contents (for example vaults intended for different purposes in the company)

If you want the metadata largely matching each other between vaults, you should consider first creating the metadata structure of the target vault through metadata structure export (see Export Structure) and then define the export and import. After this, you should verify in the target vault that the metadata structure corresponds to the use of the target vault.

Note: Metadata created after creation of the vault must be manually associated between vaults by using aliases.

Different metadata structure but partially the same content (for example, publication of certain objects from one vault to another)

If you want to publish only certain objects and metadata in the so-called publishing vault, you should create the metadata structure of the publishing vault separately from that of the source vault.

In this case, aliases must be defined for all other metadata structures than built-in ones, so that metadata can be associated when the synchronization is performed.

Associating Metadata

By default, M-Files associates metadata by the following methods (in order of relevance):

  1. The built-in metadata definitions are always automatically associated, regardless of the manner of creation of the vault metadata structures or methods of performing the association. These metadata definitions might be Name or title, Created by, Last modified by, Keywords, and so on. In publishing operations, you may want to hide some of these. For example, you may not want to show the document creator in the publishing vault. You can edit the built-in metadata to suit the publishing operation via the registry settings and permissions.
  2. All the items have a GUID (globally unique identifier). If there is a GUID match across vaults, the metadata definitions are always mapped automatically.
  3. If the aliases match between the vaults, the association of the metadata definitions is always performed. The alias must be manually defined in each vault for the metadata definition in question. For more information, refer to Aliases for Associating Metadata Between Vaults.
  4. If both metadata definition's ID and the name match, the association of the metadata is performed automatically. This default setting can be changed from the registry settings. Note that when the association is performed with name, the names in line with the default languages for vaults are used. Also note that if the metadata structures have been separately created in different vaults, the IDs are not the same and the association must be performed via aliases.
  5. You can also use the name of imported metadata definition as its alias if there are no other aliases available. In this case, you need to define the alias only in the target vault using the name of the metadata definition from the source vault. For more information, refer Use the name of an imported element as its alias if no other alias is available under Importing Content.
  6. If, in addition to those mentioned above, you want to have associations using the name only, you can include this definition in the registry settings. Then the name of the metadata definition, such as Telephone number, must be the same across vaults. When default settings are used, the name alone is not sufficient for association of the metadata. Note that when the association is performed by means of name, the names in line with the default languages for the vaults are used.

Aliases for Associating Metadata Between Vaults

Because only the built-in metadata definitions and those matching the GUID or ID and name are associated automatically, for other metadata definitions the association must be performed by using aliases.

Aliases can be used for identifying semantically equivalent metadata. For example, when importing objects from another vault, their Date and Description properties can be mapped to the target vault's equivalent properties on the basis of aliases even if the properties' internal IDs and/or names are different. That is, the aliases refer to semantically equivalent metadata in different vaults. In other words, alias is a common identifier for the same metadata definition between several vaults.

The alias is defined as a common ID with the same name in both source and target vault.

When defining the alias, you can use various external data type and archive standards, such as SÄHKE2, MoReq2, and Dublin Core.

Check that there are sufficient definitions for all desired metadata definitions so that the association can be performed. Check the following: object types, value lists, property definitions, classes and class groups, workflows and workflow states, user groups, and named access control lists. In the properties of these metadata definitions, you can find the Advanced tab, where you can define the alias(es) for the metadata definitions.

For example, the source vault has the property definition Telephone number, whose vault-specific ID is 1001. The semantically equivalent property definition is also in the target vault, but the vault-specific ID is 1005 – the name can be the same (Telephone number) or different (for example Phone and Phone number) in the default language. If you want to associate these, you must define a common alias for this property definition in both vaults. The alias can be anything you want, such as Telephone number or dc.PhoneNumber, with the exception that it cannot contain both dots and spaces.

The alias is not shown to the users in M-Files Desktop; that is, the users see the name of the vault-specific property definition, just as before.

Note: If there are several metadata definitions with the same alias in the target vault, the association is bypassed for these and the data will not be imported to the target vault.

Assigning Aliases for Metadata Definitions

  1. Open M-Files Admin.
  2. In the left-side tree view, expand a connection to M-Files Server.
  3. In the left-side tree view, expand Document Vaults, and then expand a vault.
  4. Still in the left-side tree view, expand Metadata Structure (Flat View) and select the type of metadata definition, for example Property Definitions, for which you want to assign an alias or aliases.
    Result:The list of metadata definitions is opened in the right-side panel.
  5. From the list, right-click the instance for which you want to assign an alias and select Properties from the context menu.
    Result:The Properties dialog for the selected metadata definition is opened.
  6. Go to the Advanced tab.
  7. In the Aliases field, type in the name of the alias for the selected metadata definition.
    Use the same aliases for semantically equivalent metadata in both the source and the target vault.
  8. Click OK to close the Properties dialog.
The alias is displayed in the Aliases column of the metadata definition listing.

Login Accounts

Depending on the purpose of use of the target vault, the users of the target vault may be the same as, or entirely different from, those of the source vault. If you want to grant certain users permissions for both vaults, synchronize the metadata for the Users value list, or do both, you should create user accounts with the same name for these users for both vaults. User accounts are not automatically synchronized between vaults.