Skip to content

Fix Databricks empty SELECT response type#12257

Merged
StpMax merged 1 commit into
mindsdb:releases/26.1.0from
ianu82:codex/fix-databricks-empty-select-response-type
Mar 20, 2026
Merged

Fix Databricks empty SELECT response type#12257
StpMax merged 1 commit into
mindsdb:releases/26.1.0from
ianu82:codex/fix-databricks-empty-select-response-type

Conversation

@ianu82

@ianu82 ianu82 commented Feb 27, 2026

Copy link
Copy Markdown
Contributor

Summary

  • update Databricks native_query to return RESPONSE_TYPE.TABLE whenever result-set metadata (cursor.description) exists, even when the rowset is empty
  • keep RESPONSE_TYPE.OK for statements that do not return a result set
  • add a regression test for empty SELECT behavior

Why

Empty SELECT queries were incorrectly classified as OK, which hides schema information and causes downstream metadata/table handling inconsistencies.

Validation

  • python3 -m py_compile mindsdb/integrations/handlers/databricks_handler/databricks_handler.py tests/unit/handlers/test_databricks.py
  • pytest -q tests/unit/handlers/test_databricks.py -k empty_select_returns_table (fails in this environment due to missing optional dependency appdirs)

@github-actions

github-actions Bot commented Feb 27, 2026

Copy link
Copy Markdown

All contributors have signed the CLA ✍️ ✅
Posted by the CLA Assistant Lite bot.

@ianu82

ianu82 commented Feb 27, 2026

Copy link
Copy Markdown
Contributor Author

recheck

@StpMax StpMax changed the base branch from main to releases/26.1.0 March 20, 2026 12:01
@StpMax StpMax merged commit aea51d2 into mindsdb:releases/26.1.0 Mar 20, 2026
20 of 25 checks passed
@github-actions github-actions Bot locked and limited conversation to collaborators Mar 20, 2026
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants