Category OData

Web API OData V4 Keys, Composite Keys and Functions Part 11

This article demonstrates how OData Functions can be used together with entities which have simple keys, composite keys, entity collections or used as plain simple global functions. Part 1 Getting started with Web API and OData V4 Part 1. Part 2 Web API and OData V4 Queries, Functions and Attribute Routing Part 2 Part 3 […]

Web API OData V4 Batching Part 10

This article demonstrates how batching can be used with a Web API OData V4 service and an OData C# client. This blog is part 10 of the Web API OData series. Batching can be used to optimize network usage. Batching makes it possible to send many HTTP requests as a single multiple mixed request. The […]

Web API OData V4 Cache Part 9

This article shows how easy it is to implement cache with Web API OData. Web API OData V4 now supports Etag and also If-None-Match HTTP headers. These can then be accessed and set using the ODataQueryOptions inside an OData controller. This works well and could be a possible solution if you want to implement everything […]

Web API OData V4 Using an OData T4 generated client Part 8

This article demonstrates how to use an OData generated client. The OData client is generated using a T4 template. This T4 template generator is a NuGet package which can be added to your Visual Studio. The generated C# classes from the T4 template have some drawbacks per default, but you can fulfill your standard requirements […]

Web API OData V4 Using a Singleton Part 7

This post is part 7 of the Web API and OData V4 series. This article demonstrates how to use an OData singleton with Web API. The singleton class has a list of child entities which is used to select contained entities from the SQLite database. Part 1 Getting started with Web API and OData V4 […]

Web API OData V4 Using Contained Models Part 6

This post is part 6 of the Web API and OData V4 series. This article shows how Web API 2.2 with OData V4 can use contained EntityTypes in an OData model without defining the entities on the top level. In this example, the Player entity is the route entity set. The PlayerStats can then be […]

Web API OData V4 Using Unity IoC, SQLite with EF6 and OData Model Aliasing Part 5

This post is part 5 of the Web API and OData V4 series. This article shows how Web API 2.2 with OData V4 can be used together with Unity as an IoC, Entity Framework with SQLite for persistence and also creates an OData service which can do CRUD operations. OData Model Aliasing features are used […]