Skip to content

Update mssql_odbc.py schema query to use QUOTENAME#7642

Open
gauiPPP wants to merge 1 commit into
getredash:masterfrom
gauiPPP:patch-3
Open

Update mssql_odbc.py schema query to use QUOTENAME#7642
gauiPPP wants to merge 1 commit into
getredash:masterfrom
gauiPPP:patch-3

Conversation

@gauiPPP
Copy link
Copy Markdown

@gauiPPP gauiPPP commented Feb 25, 2026

QUOTENAME will add [] around the values and this will lead to correctly handling database names, schema names and table names with spaces and other SQL syntax problematic characters.

What type of PR is this?

  • Refactor
  • Feature
  • Bug Fix
  • New Query Runner (Data Source)
  • New Alert Destination
  • Other

Description

How is this tested?

  • Unit tests (pytest, jest)
  • E2E Tests (Cypress)
  • Manually
  • N/A

SQL query in MS SQL 2022 server with previous and new query

Related Tickets & Documents

Other pull about mssql.py about the same thing.

Mobile & Desktop Screenshots/Recordings (if there are UI changes)

QUOTENAME will add [] around the values and this will lead to correctly handling database names, schema names and table names with spaces and other SQL syntax problematic characters.
Copy link
Copy Markdown
Contributor

@cubic-dev-ai cubic-dev-ai Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No issues found across 1 file

@yoshiokatsuneo
Copy link
Copy Markdown
Contributor

Same comment is applied for this PR, too.

#7641 (comment)

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants