datafusion-tui icon indicating copy to clipboard operation
datafusion-tui copied to clipboard

Add `--flightsql` paramter for `-c` and -f`

Open matthewmturner opened this issue 1 year ago • 4 comments

Maybe it makes sense to also allow using the flightsql client when using -c and -f. If so, we could add something like --flightsql for this.

matthewmturner avatar Sep 10 '24 16:09 matthewmturner

@alamb what do you think / would you find this useful?

matthewmturner avatar Sep 10 '24 16:09 matthewmturner

I think this could be useful, depending on how we envision flightsql being used

If it is to have dft be a full on flightsql client, in addition to its other roles then it makes sense. Maybe we could embed a full flightsql client, perhaps based on https://github.com/apache/arrow-rs/blob/master/arrow-flight/src/bin/flight_sql_client.rs in arrow-rs

Used like

dft flightsql -c 'show all' -h http://example.com/my_flightsql_service

The other thing we can do with flightsql is use it like a table provider

CREATE EXTERNAL TABLE flight_table AS FLIGHTSQL URL 'http://example.com/my_flightsql_service`;
SELECT * FROM flight_table

🤔

alamb avatar Sep 10 '24 19:09 alamb

@alamb ive actually already embedded the flightsql client. just needs to be run with --features=flightsql and there is a new flightsql tab (connection params are from config). i have some docs on it here

matthewmturner avatar Sep 10 '24 19:09 matthewmturner

Ah, got it - I see now how the config file would be useful 👍

alamb avatar Sep 10 '24 19:09 alamb

🎉

alamb avatar Oct 01 '24 11:10 alamb