tabs ↹ over ␣ ␣ ␣ spaces

by Jiří {x2} Činčura

ADO.NET Data Service and non-public properties in Entity Data Model

Published 2 Jul 2009 in Entity Framework and OData/Data Services (Astoria)

I was punch directly to my face right now. Everytime I’m doing some ADO.NET Data Services (Astoria) speak I’m showing simple models, with almost no modifications. And everything works great. But I found, right now, that if you have entity in your model with property access getter or setter setted to anything except public, the service will not work. Grrr.

I understand that hiding setter causes the updates or inserts to stop working. But why the getter? If I limit my entity set to i.e. AllRead, then the querying should just work. Hmm, it’s probably related to missing select support (in 3.5SP1 as well as 4.0).

Anyway it was really “interesting” ;) to find this out.