1

On the model-first approach in the designer, if I create a relationship where the cardinality on one end of the relationship is '0..1' and '1' on the other, the designer disables the 'Add Foreign Key Property to..' checkbox.

For example, say that I had an Order entity and an OrderQuantity entity, where the OrderQuantity entity simply stipulates the initial amount of Order entities available, but doesn't have to be specified. Thus an Order can have 0 or 1 OrderQuantity, and an OrderQuantity will always have 1 Order.

The same applies if I am trying to make an entity refer to previous and newer versions of itself (i.e. a node in a list).

Defining this relationship, the designer will not allow me to add foreign key properties at all, and I have to rely on the navigation methods (which are generated fine).

Has anyone else experienced this?

0

1 Answer 1

0

change the target framework of your solution to. .Net Framework 4.0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.