[Required] incorrectly added to database generated properties


When using EntityFramework and fluent configuration (or a code generation strategy without [DatabaseGenerated] attributes Ria Services will incorrectly infer that databasegenerated properties such as rowversion fields of type byte [] are required which can result in these entities not being able to be saved.

The issue has ben solved for properties with the [DatabaseGeneratedAttribute] in changeset 644c19da but the fix only worked for properties where the attribute was applied directly to the property and not for classes where it was specified in edmx or using code first fluent Api.

This should make old workarounds such as https://social.msdn.microsoft.com/Forums/en-US/9de7a69a-6dbf-4c06-aa68-62f34227dd8d/remove-required-attribute-on-entity-exposed-by-wcf-ria-service?forum=silverlightwcf obsolete.


danneesset wrote Aug 29, 2016 at 8:23 PM

Fixed in changeset a9a8520bd98e847614aa5913dee573851744ae14