Skip to content

OrderBy(x => x.Name == null) throws an error #655

@mariojsnunes

Description

@mariojsnunes

Getting this error:
{"Incorrect syntax near the keyword 'IS'.\r\nInvalid usage of the option NEXT in the FETCH statement."}

On this query:

IEnumerable<UserProfileIndex> searchResults = await query
    .OrderBy(x => x.Name == null)
    .ThenBy(x => x.Name)
    .Skip(req.Skip)
    .Take(req.Take)
    .ListAsync();

Using sql server.

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