Toad World® Forums

Lost of attributes logical name in PER


#1

Hi,
It happened to me a few times that the logical of the attributes were lost in a physical model. I have not tried to reproduce the bug from scratch, but here are some operations I did (not necessarily in order):

  • Reverse engineer a DB.
  • Do some updates to it.
  • Do a model update from the DB.
  • Generate an alter script.
  • The application crashed on a few occasions.
    -> When I started the application and loaded the model at one point, all attribute logical names of FK were back to the name of the field in the parent table (like “ID” rather that “WhateverID” that I had renamed it to when creating the FK). The attribute physical names were still “WhatverID”. The sync was lost.
    I have not found a way to fix this automatically in the application, so I had to start from scratch.
    Anyone else noticed something similar?

gabriel


#2

Hello Gabriel,

We need to ask you for more details. Thanks in advance for them.

  1. TDM version you use. (3.4.16?)

  2. Database you are working with. (MS SQL 2008?)
    Please confirm. Thanks.

  3. Please specify the process step by step. From your description, it seems you are making modifications in database and your reversed model at the same time (model update and alter script generation at one jump is not possible in TDM).

  4. You mention that the application crasshed on few occasions. Which occasions? Any screenshots? Any Eurekalog with the details?

  5. Do you use naming conventions?

  6. Is the automatic synchronization between logical and physical names turned on or off? (It is turned on by default.)
    (http://modeling.inside.quest.com/entry.jspa?externalID=3034&categoryID=158)

Thanks a lot for the information.

We look forward to hearing from you.

Regards,

Vladka + TDM Team


#3

Hi Vladka,
Sorry about the long delay to answer your questions. I do not have all the answers you’re looking fore, but here are some.
1- 3.4.16.7.
2- MS SQL 2008.
3- It’s been a long time, but here is what I remember.

  • Reverse engineer a DB.
  • Make some changes to it.
  • Because developers are what they are, some changes happen on the DB while I’m working on the model, so I do a Model update.
  • At one point, I noticed that the column logical names of the parent tables in the child tables were renamed to the logical name in the parent table. For example, let’s say you have:
    Person (ID, Name) and PersonGroup (ID, Name, Description)
    I create a relation between Person and PersonGroup, so that I end up with
    Person (ID, PersonGroupID, Name) with PersonGroupID being the column with the FK constraint on PersonGroup.ID.
    I am not sure if it was after a model update, or after reloading the project file after a TDM crash, but I ended with all my tables being like Person (ID, ID, Name).

4- I get frequent crashes during a model update, a reverse engineering for a Sync and Convert, or a generate alter script operation (during the comparison of the differences).
5- No, all default stuff.
6- No.


#4

Hi,

Thanks for your reply.

To sum up:
PersonGroup (ID, Name, Description)
Person (ID, Name)
ID are PKs in both the entities.

You create a relationship from PersonGroup (parent entity) to Person (child entity). ID attribute from PersonGroup migrates to Person. Now in Person entity there are two ID attributes. Before you do the model update, do you rename the FK attribute to PersonGroupID or do you map the keys?

4- I get frequent crashes during a model update, a reverse engineering for a Sync and Convert, or a generate alter script operation (during the comparison of the differences).

We’re very sorry to hear this. As soon as an error occurs, please do send us the details + Eurekalog, some screenshots etc., so as we can identify the problem and fix it. In any case, when an error occurs, do NOT continue working with TDM without restarting it. Always restart TDM.
Thanks.

Regards,

Vladka + TDM Team