Exercise 13: Further uses of the group attribute
The ability to append data to an existing list allows new values to be added to columns over time. One issue that may arise is the need to append values to more than one column, ensuring that related values are all added at the same row position.
At the end of the previous exercise, the Associations tab of your Parties record will display as follows:
To prepare for the next exercise:
- Delete the last three attachments.
- Select Curator from the Role Lookup List for Graham Duffy.
The Associations tab should display as follows:
- Modify
exercise12_append_train1.csv
, whereTrain1
is your login name as follows:Column Name
(Row 1)
Record 1
(Row 2)
irn
[Your IRN]
AssAssociationRef_tab(+).NamFirst
Henry
AssAssociationRef_tab(+).NamLast
Noremark
AssRole_tab(+)
Curator
Our objective is to append a new Parties record for a curator, Henry Noremark.
- Save the file and perform a Typical import.
The result is not as expected and while the new Parties record is appended, the role has been applied to the incorrect party:
Again, we're faced with the issue that the Import Tool does not know the relationship between columns. And again, the solution is to use the
Group
attribute. - Modify
exercise12_append_train1.csv
, whereTrain1
is your login name as follows:Column Name
(Row 1)
Record 1
(Row 2)
irn
[Your IRN]
AssAssociationRef_tab(+ group='1').NamFirst
Kathie
AssAssociationRef_tab(+ group='1').NamLast
Reed
AssRole_tab(+ group='1')
AssAssociationRef_tab(+ group='2').NamFirst
June
AssAssociationRef_tab(+ group='2').NamLast
Brown
AssRole_tab(+ group='2')
Curator
This time the results are as expected:
Note: The
Group
attribute may be used with nested tables in the same way they can be with tables.

Step 3:
<?xml version="1.0" encoding="UTF-8"?>
<table name="eparties">
<tuple>
<atom name="irn">191</atom>
<table name="AssAssociationRef_tab">
<tuple row="+">
<atom name="NamFirst">Henry</atom>
<atom name="NamLast">Noremark</atom>
</tuple>
</table>
<table name="AssRole_tab">
<tuple row="+">
<atom>Curator</atom>
</tuple>
</table>
</tuple>
</table>
Step 5:
<?xml version="1.0" encoding="UTF-8"?>
<table name="eparties">
<tuple>
<atom name="irn">191</atom>
<table name="AssAssociationRef_tab">
<tuple row="+" group="1">
<atom name="NamFirst">Kathie</atom>
<atom name="NamLast">Reed</atom>
</tuple>
<tuple row="+" group="2">
<atom name="NamFirst">June</atom>
<atom name="NamLast">Brown</atom>
</tuple>
</table>
<table name="AssRole_tab">
<tuple row="+" group="2">
<atom>Curator</atom>
</tuple>
</table>
</tuple>
</table>