views:

20

answers:

1

when i create my entity data model i have a situation in the DB like this : TableFirst : [Id,IdTableSecond,IdTableSecondAgain];TableSecond[Id]

Created data model is: TableFirst.TableSecond and TableFirst.TableSecond1

Question is: Every time when i create my entity TableFirst.TableSecond will have same relation in behind (IdTableSecond) and TableFirst.TableSecond1 (IdTableSecondAgain)

or they may change?

PS:sorry for my english.

A: 

You should rename the TableFirst.TableSecond and TableFirst.TableSecond1 navigation properties to something meaningful, and whenever you update the model from the database, they will NOT get overriden (you will keep your meaningful names).

Yakimych
My DB is so big and changes is so often that i can not update, i shuld recreate it.
Artiom
Then yes, you do have a problem: http://stackoverflow.com/questions/3360851/entity-framework-naming-of-model-with-same-types
Yakimych