Description of issue:
All my queries that are saved (published or not) fail to run and throw an error. However copy pasting the same sql code into a new query returns the results as expected just like before the upgrade.
STR:
Open a saved querry
Click execute
Read error “Error running query: No data was returned.”
Copy the SQL
Click New Querry
Paste and execute
Read results = all Ok.
So any ideas what is causing the issue that saved queries will not run and throw an error?
I have tried rebooting the whole machine and it is still the same. I am not sure if there are more detailed logs stored somewhere that might give a hint.
Hmm just found something interesting. It is not related to that end point at all.
It appears that any call will fail if there is any commented out text after the SQL statement.
Example:
This call returns the result as expected
Body:
{“data_source_id”:2,“query”:“select * from region_lookup”,“max_age”:0,“query_id”:36}
This call returns the error:
Body:
{“data_source_id”:2,“query”:“select * from region_lookup;\n/* foo bar */”,“max_age”:0,“query_id”:36}
It seems the ending of the SQL with the “;” will result in a broken querry if anything comes after it. This does not apply to other front end SQL services like phpmyadmin when testing but it is likely they strip out my comments at runtime before passing it to the engine.
Now I know the issue I can go back and fix my queries but I am wondering if it was intended in the update. As it was not an issue in the older version of redash.
Login or sign up disabled while the site is in read only mode