KNOWLEDGE BASE
Log In    |    Knowledge Base    |    4D Home
Tech Tip: Avoid adding tables to multiple copies of a structure
PRODUCT: 4D | VERSION: 12.5 | PLATFORM: Mac & Win
Published On: August 27, 2013

If using multiple copies of a structure and developing in both; make sure that if adding a table, field, or index, that it is only added to the master copy.

Any table or field added to the structure will have a unique ID (UUID) associated with it. Any data created with that structure is placed in the data file with the same UUID reference as the structure file used for opening the database.

If a table or field is added to the structure in multiple copies they will have different UUIDs. Since the data is stored with the UUID of the structure, the data will only be accessible to the structure used for adding that data.

Lets say in Structure #A a table named Table_A is added and it is automatically assigned a uuid of ABC123.
Then, in Structure #B a table named Table_A is also added and it is automatically assigned a uuid of XYZ987.

Data added to Table_A from Structure #A will only be accessible to Strucutre #A as it will have a UUID of ABC123.

If Structure #B attempts to load the data file from Structure #A the values associated with UUID ABC123 will not be visible as Structure #B is trying to use UUID XYZ987. In other words this data will be lost.

In this situation, running a Recover By Record Headers in v12 will show that there are tables with an 'unidentified destination' in the data file.

This type of situation should be avoided.