Skip to content

OrderBy() and OrderByDescending() return wrong results when used with bool properties #42

Open
@Ahmed-Abdelhameed

Description

@Ahmed-Abdelhameed

The following query:
context.Items.OrderBy(x => x.IsActive);
..returns items with IsActive == true first then those with IsActive == false (should be the opposite).

Similarily, the following query:
context.Items.OrderByDescending(x => x.IsActive);
..returns items with IsActive == false first then those with IsActive == true (should be the other way around).

This seems to be a bug in JetEntityFrameworkProvider because it works the right way with SQL Server and, of course, with any other collection. As a workaround, I'm currently using context.Items.ToList().OrderBy....

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions