Skip to content

Add support for querying over TableEntityRepository #231

@kzu

Description

@kzu

The really nice LINQ queries over the custom-typed ITableRepository<T> is so useful that it's a pity we don't have the same for generic TableEntity repository.

We should enable that and allow the same code to use either custom types or generic entities for querying and projecting.

In particular, we should be more flexible in what projections are allowed, since we do allow any custom type deserialization (for the regular ITableRepository<T>, so we could offer something the OOB table APIs don't allow, which is rich project to anonymous types.

Example:

var query = from book in repo.CreateQuery()
            where
                book.PartitionKey == "Rick Riordan" &&
                book.RowKey.CompareTo("97814231") >= 0 &&
                book.RowKey.CompareTo("97814232") < 0
            select new { Title = (string)book["Title"] };

Back this issue
Back this issue

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions