Versioning of StructureValue and StructureAttribute

This article applies to Informatica PIM in versions 7.0 and above.

Changes in the UI

You won't see this error message again:

images/download/attachments/29818964/Error_message_when_trying_to_delete_a_pool_feature.JPG

Especially you can now edit or delete structure attributes and structure values in the head revision and the versioned data won't be changed.

If you look at attributes and values in a version you will notice that they are now displayed with a yellow background like every other versioned object.

images/download/attachments/29818964/StructureAttributeStructureFeatureInVersion.JPG

Changes in the database

StructureAttribute

There's a new table StructureAttributeRevision containing all columns which were in the StructureAttribute table before.

The new table has a foreign key StructureID. StructureAttribute had a reference to StructureRevision.ID before.

Of corse StructureAttributeRevision has a new foreign key relation to StructureAttribute.

The available reserved fields are the same as before.

StructureAttrAuditLog, StructureAttributeLang and StructureAttributePresetVal now have a foreign key StructureAttributeRevisionID.

images/download/attachments/29818964/DB_StructureAttribute.jpg

StructureValue

There's a new table StructureValueRevision containing all columns which were in the StructureValue table before.

The new table has a foreign key StructureId. StructureValue had a reference to StructureRevisionId before.

Of corse StructureValueRevision has a new foreign key relation to StructureValue.

The available reserved fields are the same as before.

StructureValueAuditLog, StructureValueLang and StructureValueSynonym now have a foreign key StructureValueRevisionID.

images/download/attachments/29818964/SB_StructureValue.jpg

If your customer already uses versioning, be aware of the following:

There is no update script which migrates the data of structure attributes and values which are implicitly referenced in a structure revision!

What we did: For each entry in the StructureAttribute table a new entry in the StructureAttributeRevision table was created with RevisionId = 1 and all values for this entry have been copied from the corresponding columns in StructureAttribute.

What we didn't do: Before, if you versioned a structure with structureAttributes, there was no new entry in the StructureAttribute table. Instead it was searched for references from the objects in a specific version to this structureAttribute/structureValue and if found it couldn't be changed or deleted. So, what needs to be done in case versioning has been used before is: For each structureAttribute/structureValue take the structureRevisionId and find out the structureId, then find all entries in the StructureRevision table and duplicate the structureAttribute/structureValue entry for each structureRevision to the given previously found structureId and copy the revisionId from the structureRevision entry to the new structureAttribute/structureValue entry.

Fragments

StructureAttributes, StructureValues and their subentities now use FragmentHQLs. The stored procedures used before are gone.

Changes in the repository

StructureGroup:

StructureGroupAttributeType.StructureAttributeId became a proxy. The Identifier changed to StructureGroupAttributeType.StructureAttribute. Also the Proxy Transition Entity is set, so that transitions can be used.

StructureFeatureType/StructureValueType:

The necessary changes of persistence-model-class, persistence-xpath, fragment-column-access, revision-property and revision-persistence-class have been made.