Skip to content

Multiple bindings with the same value #666

Description

@fairking

I am trying to get some query working which includes binding value multiple times:
eg.

.OrderByRaw("CASE WHEN StartDate < ? and (EndDate is null or EndDate > ?) THEN 0 WHEN StartDate > ? THEN 1 ELSE 2 END",
                        bindings: new object[] { DateTime.Today, DateTime.Today, DateTime.Today })

Is there any way to modify query in a way, so the DateTime.Today declared only ones.

Doc says nothing about that.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions