Problems with EDM Associations

I make an OData service and use EDM to map the structure of my database and determine the relationships between tables and create navigation properties.

I imported my tables into EDM using a wizard. Things compile until I turn on associations. I am sure that I was able to do this earlier, but for some reason this is screwed on.

I have a table attribute

AttributeId     int   PK
AttributeName   varchar(100)

and

AttributeItem
AttributeItemId       int PK
AttributeID           int
AttrributeItemValue   varchar(100)

I want to associate an AttributeId between two tables with a ratio of 0..1 to * (from attribute to attribute).

I am constantly having problems. initially this error:

Error 3027: mapping not defined for next EntitySet / AssociationSet - AttibuteAttributeItem

Then, as soon as I stumbled with association mapping data, I get this error:

3024: , 91: (AttributeItemId, AttributeId) End AttributeItem AttributeAttributeItem .

, .

, ?

,

+3
1

Assotiation . . "Generate Database" , EDM. , edmx " ..." XML, (91).

+1

Source: https://habr.com/ru/post/1765832/


All Articles