Skip to content

Consider simplifying SQL parameter names (@__city_0 -> @city) #35113

Description

@roji

All our SQL parameters have a __ prefix; this is the result of an internal detail: the prefix allowed us to distinguish between query parameter (captured variables) and lambda parameters; we're effectively leaking an internal implementation detail to our SQL shape. #35089 removes this need: the two parameter types (query, lambda) are now clearly distinguished via different node types. Since the prefix is no longer needed for EF's purposes, it can be removed, simplifying our parameter names.

We can also take this opportunity to make some other simplifications. For example, we append a running counter to parameter names in case the same name is used twice - an exceedingly rare situation. We can append the number only for that case, leading to most parameters being named more naturally (@city).

Activity

  1. added this to the 10.0.0 milestone on Nov 14, 2024
  2. self-assigned this
    on Nov 14, 2024
  3. added 2 commits that reference this issue on Nov 25, 2024
    c6743ab
    cb5c2a4
  4. added 3 commits that reference this issue on Nov 25, 2024
    c6e0f64
    49fb359
    3fc90ba
  5. added a commit that references this issue on Nov 26, 2024
    d1e1dfa
  6. added theissue type on Jun 15, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Projects

No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions