redash
redash copied to clipboard
Can't connect to MS SQL data source
Discussed in https://github.com/getredash/redash/discussions/5948
Originally posted by gdaitis March 29, 2023
Hey guys! I'm trying to connect to a MS SQL data source, and I'm getting this weird error:
What am I doing wrong?
What version of Redash are you using?
Ahhh. This one I've seen before. It seems to be some kind of bug in the part of the Dockerfile which pulls in the MS SQL ODBC driver:
https://github.com/getredash/redash/blob/ad7d30f91de64a291eb89892c713bd0067c47ecc/Dockerfile#L66-L81
The second half of that code, where it installs "Simba ODBC" somehow kills the MS SQL driver files.
So, if you delete line 73-81, then remove the trailing /
left over on line 72... the Dockerfile should then build ok and the SQL Server connection will work:
https://github.com/getredash/redash/blob/ad7d30f91de64a291eb89892c713bd0067c47ecc/Dockerfile#L73-L81
Discovered the same thing recently, and did effectively that (but a bit messier) to solve it. Haven't followed that up to make a "proper" solution/patch though. :innocent:
@arikfr This bug might interest you, as you've been doing stuff on that section of the Dockerfile recently. :smile:
Thanks for the tag, @justinclift. I think what happens here is that the Simba driver fails to install because it’s not compatible with ARM.
Either way Databricks has a native Python driver now and I plan to switch to it to avoid the need for Simba.
@arikfr Is this the Databricks python package you're meaning?
https://pypi.org/project/databricks-sdk/