Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

If the virtual (SQL) dataset contains a comment, not possible to synchronize the columns #25527

Closed
bu3tt1 opened this issue Oct 5, 2023 · 1 comment

Comments

@bu3tt1
Copy link

bu3tt1 commented Oct 5, 2023

If the virtual (SQL) dataset contains the comment --SELECT in the clause select is not possible to synchronize the columns.

How to reproduce the bug

  1. Go to 'Edit Dataset'
  2. Modify the query SQL on the virtual (SQL)

SELECT
issues.id
--SELECT
FROM issues

  1. Save
  2. Return on 'Edit Dataset' > 'Columns'
  3. Click 'Sync columns from source
  4. See error:

(1064, "You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'SELECT\nFROM issues\nLIMIT 1' at line 3")

Expected results

Columns must synchronize without error

what actually happens.

Screenshot 2023-10-05 alle 11 10 54 Screenshot 2023-10-05 alle 11 11 03

Environment

  • superset version: 2.1.1
  • official Docker image: apache/superset:2.1.1
@rusackas
Copy link
Member

This doesn't seem to be an issue in current Superset on master - or at least I wasn't able to reproduce it with the example (BIrth Names) dataset.

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

No branches or pull requests

2 participants