Skip to content

Commented text incorrectly identified as parameters #1008

@vicnett

Description

@vicnett

Bug Description

If there is text preceded by a dollar sign in a comment, executing the statement with DBCode triggers a prompt for "Parameter Values."

In that prompt, clicking "Cancel" aborts and the statement is not run. Clicking "Continue" prompts to start a pro trial, and then clicking "Cancel" executes the statement (so, this is a workaround).

Repro steps

  1. Add a comment containing a dollar sign followed by test ($ alone does not cause the issue) to any SQL notebook cell or SQL file
  2. Execute the statement with DBCode
  3. Get prompted for parameter values

Expected Behavior

Commented text should not be parsed for parameters, and I would expect my statements to simply run as normal. Mentioning dollar amounts in comment is common and should not cause issues.

Actual Behavior

SQL is parsed for text that looks like parameters, including commented out text (with --).

Environment

  • DBCode version: 1.28.11
  • VS Code (or fork) version: Windsurf 1.9566.11
  • OS: Linux
  • Database: MySQL 8
  • Connection: SSH

Screenshots

Image

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