ibis-project / ibis

the portable Python dataframe library
https://ibis-project.org
Apache License 2.0
5.02k stars 585 forks source link

feat: Teradata (TD) backend #7040

Open LVG77 opened 1 year ago

LVG77 commented 1 year ago

Is your feature request related to a problem?

No response

Describe the solution you'd like

I'd like to use ibis for working with data in Teradata. Are there any plans to implement an ibis backend for it? It seems like Google's professional-services-data-validator tool has integrated a TD backend using ibis framework (see ibis_teradata). Maybe this functionality can be ported relatively easily. Thank you for this wonderful library!

What version of ibis are you running?

6.2

What backend(s) are you using, if any?

No response

Code of Conduct

gforsyth commented 1 year ago

Hey @LVG77 -- thanks for opening this! And we're glad you're using Ibis!

We generally need to have a means of testing a backend in CI (maybe this works? https://hub.docker.com/r/teradata/python-teradatasql) and the Google provided backend looks reasonably up-to-date.

It probably wouldn't be a huge lift to port this backend over, although getting the test suite passing is often a bit of a slog.

This isn't a current priority for us, but we'd certainly welcome any contributions adding the Teradata backend and we'll probably get to it eventually.

Pibbers commented 7 months ago

@gforsyth If you are looking for a Teradata environment to test against you can sign up for a free one here. API access is also available for this environment. https://clearscape.teradata.com/

Alternatively, you could make use of the new Teradata self-service, on demand platform which will enter public preview in Q2-2024 for AWS & Azure (and later in 2024 for GCP) and be able to access and control via CLI and API calls. https://quickstarts.teradata.com/ai-unlimited/getting-started-with-ai-unlimited.html

Both are complete Teradata Vantage SQL engine implementations and all syntax is supported.

lostmygithubaccount commented 7 months ago

hi @Pibbers, thanks for the pointers! we don't have the capacity to add new backends at this point, though we have been helping companies (e.g. Exasol and RisingWave) PR their own backends recently. if you or anyone else are interested in adding a backend for Teradata it'd be appreciated! otherwise this probably won't be something we get to for a while

datajoely commented 4 months ago

Hi @lostmygithubaccount - just in case you need some user validation, we have a big teradata deployment coming up that I'm keen to push Ibis for, this would be super helpful!

lostmygithubaccount commented 4 months ago

that's good to know! it's still not likely something the core Ibis team can prioritize in the next 3-6 months given the current focus on API stability (which will get us to the point where it's even easier to add and maintain new backends, like Teradata). this is something we'd welcome a contribution for, however, and most of the pieces are there:

  1. DBAPI driver: https://github.com/Teradata/python-driver
  2. SQLGlot dialect: https://github.com/tobymao/sqlglot/blob/main/sqlglot/dialects/teradata.py
  3. Testing environment (the above container Gil linked): https://hub.docker.com/r/teradata/python-teradatasql

if anyone is interested in contributing, let us know here and we can collaborate on next steps