artiomchi / FlexLabs.Upsert

FlexLabs.Upsert is a library that brings UPSERT functionality to common database providers for Entity Framework in their respective native SQL syntax
MIT License
516 stars 81 forks source link

Entity fields not recognized #122

Open MelGrubb opened 2 years ago

MelGrubb commented 2 years ago

I am still diagnosing this and reading through your code to make sure I have this right, but it appears from the outside that it is only paying attention to properties on the entity class and ignoring fields. We have some fields that are mapped to the table for reasons I won't go into here, but only the properties are getting set. Since the fields are required on the database though, the "sert" part of "upsert" always fails. If the entity exists in the database, then the update operation works, although I suspect it's still leaving those fields out of the statement.