Altova RecordsManager

To access the data table operations described in this topic, do the following: In the Database Structure tab of the Configuration Page, expand the data table by clicking its name (see screenshot below).

Click to expand/collapse

Then click More.

 

Add (parent/child data table to current data table)

Click More (see first screenshot of this topic). Depending on the current data table, you can add a parent data table (with the Add Parent Data Table button) and/or a child data table (with the Add Child Data Table button); see screenshot below.

Click to expand/collapse

The procedure to create the parent or child data table is the same as that for any new data table.

 

Duplicate (current data table)

Click More (see first screenshot of this topic). The Duplicate operation creates a duplicate of the current data table with all fields, filters, and forms. The duplicate is created as a sibling of the current data table. However, record data will not be copied.

Click to expand/collapse

Give the duplicate data table a new name and click Continue. You can subsequently edit the newly created data table in the usual way.

 

Remove (current data table)

Click More (see first screenshot of this topic). The Remove operation enables you to:

 

Delete all the records of the current data table and its descendant data tables.

Remove the current data table and all its descendant data tables, together with all records in these tables.

Remove the current data table and all its records. If the data table contains child data tables, these will not be removed, but will be connected to the parent of the current data table.

Click to expand/collapse

 

Loose Link

Click More (see first screenshot of this topic). The Loose Link operation is available for all data tables except top-level data tables. The Loose Link operation enables the link to the parent data table to be converted to a loose link (see screenshot below). If the relationship is a loose link, records of this data table will be created independently of the former parent, and will be linked to the former parent only when required, via forms. As an independent, loosely linked child, the records of the data table will not be deleted if records of the parent data table are deleted.

Click to expand/collapse

For more information about hierarchies and links between data tables, see the topic Database Structure.

 

Parent/Child

Click More (see first screenshot of this topic). The Parent/Child operation is available for top-level data tables only (see screenshot below). A top-level data table can be converted to a child data table of another top-level data table and moved to the corresponding position in the hierarchy.

Click to expand/collapse

For more information about hierarchies and links between data tables, see the topic Database Structure.

 

Change Repository

Click More (see first screenshot of this topic). The Change Repository operation is available for top-level data tables only (see screenshot below). A top-level data table and its descendant data tables can be organized into another existing repository.It will be a sibling of the top-level data table/s of the repository to which it is moved.

Click to expand/collapse

For more information about hierarchies and links between data tables, see the topic Database Structure.

 

Import Records

Click More (see first screenshot of this topic). The Import Data operation enables you to import data from an XML file that has a structure corresponding to that of the current data table's hierarchy. Two types of import are possible:

 

Import the records of a top-level data table, including records of its descendant data tables. Click Import <data table> and child records to do this.

Update selected fields of the records of any data table. The records to update are selected on the basis of the field/s you select as the key field/s. Click Update <data table> records with imported data to do this.

Click to expand/collapse

Import records of top-level data table

After you create a data table, you can import its records and the records of descendant data tables from an XML file. The XML file must have a structure that matches the structure of the data table and its descendants. After you click Import <data table> and child records, generate an XML Schema that defines the structure of the XML file by clicking Save XML Schema. The schema file will be downloaded to the Downloads folder of your client device.

 

Note the following points about the import:

 

If a field has been defined as a required field of a data table, then the element corresponding to this field must be present in the XML file. Otherwise, the import will fail.

If a field has been defined as a optional field of the data table, then the element corresponding to it is optional in the XML file as well.

Child elements are optional. This means that you can import a top-level data table only, or the top-level data table plus descendant data tables down to any desired depth.

Date, time, and number fields must be in ISO format (respectively: 2020-12-31, 18:25:26, and 1234.56).

File fields are imported from an element named <Files FileName="" />, and element content must be base64-encoded. The FileName attribute is optional.

Image fields are imported from an element named <Images FileName="" />, and element content must be base64-encoded. The FileName attribute is optional.

Reminder fields cannot be imported.

Link-to fields are imported from an element named <Link-to />. It must contain the identity value of the referenced record. For example, if the record of a certain contract links to a department's Name field, then the XML file could have: <Link-to>Accounts</Link-to> in order to link this contract to the Accounts department.

 

Update records of a data table with imported data

The records of a data table can be updated with data from an XML file. The XML file must have a root element named Root that has child elements corresponding to the records of the data table. For example, a data table named Person would have multiple Person records. The data in these records can be updated with data in an XML file that has a structure something like this. The child elements of the Person element in the XML file must correspond to the fields of the Person data table.

 

<Root>

  <Person>

     <Department>Sales</Department>

     <First>Jim</First>

     <Last>Gridely</Last>

     <Title>Executive</Title>

     <Phone>123456789</Phone>

     <Email>legal.01@redmaple.com</Email>

  </Person>

  ...

  <Person>

     <Department>Accounts</Department>

     <First>Jane</First>

     <Last>Locke</Last>

     <Title>Manager</Title>

     <Phone>123789777</Phone>

     <Email>accounts.04@altova.com</Email>

  </Person>

</Root>

 

 

The data from the XML file that will be used for the update is selected in two steps:

 

1.Select the field/s of the record that will be used to uniquely identify the record in the XML file. You can choose any number of fields (from one field to all fields).

2.Select the fields of the record that you want to update. The field/s that were selected as the identifier field/s will not be changed. The data in fields that have not been selected for update can be either (i) kept unchanged, or (ii) removed.

 

Update Records

Click More (see first screenshot of this topic). The Update Records option (screenshot below left) enables you to update a field of all or selected records. Click Update <data table> Records to open the Update Records Settings form (screenshot below right).

Click to expand/collapse     Click to expand/collapse

The Update settings are as follows:

 

Select what records to update: either all the records of the data table, or a subset of records selected by one of the data table's filters.

Select the field to be updated.

Enter the new value to write into the selected field of the records to be updated. The value is calculated via an XPath expression. In the screenshot above, we are updating the Review Date field with the contents of the Expiry Date field. As another example, you can update the Email field of each record with an email address that will have the pattern: FirstName.LastName@altova.com., where FirstName and LastName are taken from the First and Last fields of the respective records.

 

You can click Preview to confirm that the XPath expression returns what you expect for each record. When you are sure that you want to implement the change, click Update Now.

 

© 2018-2024 Altova GmbH