Azure / azure-cosmos-table-dotnet

.NET SDK for Azure Cosmos Table API
14 stars 6 forks source link

EntityProperty fixed types don't match REST API #35

Open davidmatson opened 4 years ago

davidmatson commented 4 years ago

The EntityProperty class has a bunch of validation (calls to this.EnforceType) that prevent turning a property of one type into another type.

The REST API for tables allows changing the property of a type when updating/merging. To be more precise, it doesn't even care what the old type was - the type of the property is determined by what is specified anytime the property is created/replaced/merged.

To match, the .NET API should likely not prevent reading a property as one type and then changing it to another type to write it back to the table.

(Copied from Azure/azure-storage-net#554.)