Export profiles

Administration PageApplication/ContractSyracuse/CollaborationClassexportProfilesRepresentationexportProfile

The export profile describes a data model used to extract data from a V12 repository in a JSON file. This file can be integrated in another V12 repository through the import tool.

This is a technical function currently reserved to advanced users. If your intention is only to export data related to user personalization, you can directly use the personalization management. But if you need to export data from other entities, you can use this tool that is more technical.

The data model includes at least one entity to be exported. Mandatory fields referring to another entity may be present in which a description of the destination entity with its access keys must be done to enable, prior to export, getting a list of references that link the exported entity to this other entity.

It is not mandatory to include the data from the linked entity. The import of the extracted data will work only if the references can be resolved during import time, but the linked entity might have been imported separately or updated manually.

When the query page is displayed, a list of the existing export profiles appears.

Information to be entered

The following information is available on the detail and edit page.

Code

This mandatory field identifies the export profile.

Description

This mandatory field describes the profile.

Application

This mandatory field defines the application in which the connection is done to extract the data. It can be a 'Syracuse collaboration' or 'Sage X3'.

Endpoint

This mandatory field indicates the endpoint from where the data will be extracted.

Profile items

In this array, you can describe a list of entities that will be exported. Lines can be added on a per line basis, or globally by selecting the '+Add' link.

For each listed entity, a list of information must be entered, either directly on the line or on tabs that can be opened for every line by clicking the chevron on the line. The information to be entered is the following:

Class name

Identifies the class to be exported.

Title

Description of the class to be exported.

Standard profile

When this check box is selected, a standard profile is used.

Filter

Allows you to set up a filter in SData where syntax.

Export all

When this check box is selected, all the records that fulfill the stated SData condition are exported. Otherwise, a list will appear on the Exported object tab. If the tab is blank, then the data will not be exported. The key values that refer to this entity will be present in the other records referring to it, and the key description will be given in the "$prototype" section of the data export.

Exported objects

This tab opens for the current line and displays a list of references on the entity to be exported only if some records are affected by this export. This will be used only if the Export all check box is cleared.

Profile Item Key

This tab describes the identifiers of the record for the given entity. They are selected within the list of properties present in the entity.

Profile Item Attributes

This tab describes the attributes that have to be exported for the entity. They can be selected within the list of properties present in the entity.

Links available

The export operation is available from the export profile definition. The following links are available:

Export profiles

This link triggers the execution of the export. A popup page opens to define the export options.

Target type

This field provides a choice between three different destinations for the export result, and allows you to enter the related information.

Direct download

This link triggers the execution of the export and downloads it. The program to be used to display the result of the import must be selected before the data is visible.

Appendix: format of the export

General structure

The export tool generates a JSON that contains three sections (the last one being optional):
{ "$prototypes": {"firstEntity" : { },"secondEntity" : { },...},"$items": [{"$type": "firstEntity",...},...],"$localization": {"language_1" : {"keyvalue1": "localized_text1_1","keyvalue2": "localized_text1_2"},"language_2" : {"keyvalue1": "localized_text2_1",...}}

The prototype section

The "$prototype" section contains a description of the key attributes for every entity that has been selected in the export profile. It does not contain the description of all the attributes, but only the key description, the attributes that are references to other attributes, and the localized (for example, translatable texts) associated with the data.

Let's consider the following group of data:

If we generate an export file from such a template when connected with en-us locale, the prototype section generated will be the following:
 "$prototypes": {"document": {"$key": [ "description.en-us", "volume" ],"$localized": [ "description", "description" ],"volume": { "$key": "code" },"owner": { "$key": [ "firstName", "login", "lastName" ] },"tags": { "$key": "description.en-us" }},"documentTag": {"$key": "description.en-us","$localized": [ "description", "description" ],"category": { "$key": "description.en-us" }},"storageVolume": {"$key": "code","$localized": [ "description" ]},"user": {"$key": [ "firstName", "login", "lastName" ]},"documentTagCategory": {"$key": "description.en-us","$localized": [ "description", "description" ]}},"$items": [ {...

The data section

The "$item" is a collection that provides all the elements. Each element is defined by a "$type" that indicates the entity, followed by the list of properties and their values (collection is presented as JSON collections).

The following example provides the previous structure using different items (the PDF contents of the document that is normally shown in encoded format has been shrunk).
"$items": [{ "$type": "document","description": "description_d8bb7098-67b6-4398-9bfe-c5e60b7007af","documentType": "application/pdf","documentDate": "2013-11-26","fileName": "PURFCS.pdf","content": {"length": 1213,"contentType": "application/pdf","fileName": "PURFCS.pdf","uploadDate": "2013-11-26T16:01:44.412Z","chunkSize": 262144,"$content": "JVBERi0xLjcgCiXi48/TIAoxIDAgb2...T0YNCg=="},"volume": "PRINTS","owner": {"firstName": "John","login": "JDOE","lastName": "DOE"}},{ "$type": "document",...},{ "$type": "user","login": "JDOE","title": "Mr","firstName": "John","lastName": "DOE","active": true},],"$localization": {....

The localization section

The "$localization" section contains the localized texts per language. In the "items" section, a localized description is generated with "description" followed by a unique ID, such as this line:
 "description": "description_b03e2cf7-fe9f-4f2f-b0f3-b59e7a080961"
In the localization section, for every language, the different descriptions will be found, like the example above:
 "$localization": {"en-us": {"description_b03e2cf7-fe9f-4f2f-b0f3-b59e7a080961": "English text""description_d8bb7098-67b6-4398-9bfe-c5e60b7007af": "Accountant",...},"fr-fr": {"description_b03e2cf7-fe9f-4f2f-b0f3-b59e7a080961": "Texte français""description_d8bb7098-67b6-4398-9bfe-c5e60b7007af": "Comptable",...},"de-de": {"description_b03e2cf7-fe9f-4f2f-b0f3-b59e7a080961": "Deutsches Text""description_d8bb7098-67b6-4398-9bfe-c5e60b7007af": "Buchhalter",...},"es-es": {"description_b03e2cf7-fe9f-4f2f-b0f3-b59e7a080961": "Texto en español""description_d8bb7098-67b6-4398-9bfe-c5e60b7007af": "Contable",...},...

Associated errors

At execution time, errors can be displayed in red, and warnings are displayed in yellow.

Errors

The errors displayed are linked to a reference in the data set that has not been described:

Export profile item not defined for xxxxx

The meaning of this message is that the xxxx property refers to an entity that has not been included in the description.

For example, if you export documents that have a volume property defined as a reference to the storageVolume entity, the message will be as follows:
Export Profile Item not defined for storage volume.

Warnings

The warnings are displayed when a reference is missing. It applies only to a property that is not exported:

xxxx is a mandatory property/relation for yyyy, but not selected for export.

For example, when you export the documents without exporting the owner (that links to a user), if the user entity is not described in the model, the following message will appear:
owner is a mandatory property/relation for documents, but not selected for export.