treasure-data / prestogres

PostgreSQL protocol gateway for Presto distributed SQL query engine
Other
292 stars 61 forks source link

Connecting to Tableau 8.2 #21

Open arthurhsk opened 10 years ago

arthurhsk commented 10 years ago

Hi,

I have prestogres up and running now. I just tried to use tableau 8.2 to connect Prestodb.

Q1: If I specify "default" as the database name, I cannot connect Tableau to PrestoDB, Connect on a server: select PostgreSQL sever: localhost port: 9900 database: default Error: Unable to connect to the ODBC data source, FATAL: database “default” does not exist.

Q2: If I specify "Postgres" as database name,
Connect on a server: select PostgreSQL sever: localhost port: 9900 database: postgres I can log into PrestoDB, but it cannot display any table

On the command line, I can see "default" DB exists postgres=# \l List of databases Name | Owner | Encoding | Collation | Ctype | Access privileges -----------+-------+----------+-----------+-------+------------------- default | pg | UTF8 | C | C |

My PrestoDB version is v0.79

Could you share how you get Tableau connected to Presto? Regards Arthur

arthurhsk commented 10 years ago

(Forgot to mention: Above tests are done in Tableau 8.2 for Mac.)

Have just tried Windows Tableau (Windows 8.1, Tableau 8.2, Presto 0.79): Also installed Tableau's PostgreSQL ODBC driver.

The schema "Default" can be displayed in Windows version, can get the list of tables as well. However, if drag any table to worksheet area, it always returns error "Could not send Query/connection dead)

Please help!

arthurhsk commented 10 years ago

Also for the log, I found following:

< 2014-11-19 23:47:16.400 HKT >WARNING: Result column "?column?" is renamed to "?column?_" because the name appears twice in a query result < 2014-11-19 23:47:16.400 HKT >CONTEXT: PL/Python function "run_system_catalog_as_temp_table" < 2014-11-19 23:47:16.400 HKT >WARNING: Result column "?column?" is renamed to "?column?" because the name appears twice in a query result < 2014-11-19 23:47:16.400 HKT >CONTEXT: PL/Python function "run_system_catalog_as_temp_table" < 2014-11-19 23:47:16.400 HKT >WARNING: column "?column?" has type "unknown" < 2014-11-19 23:47:16.400 HKT >DETAIL: Proceeding with relation creation anyway. < 2014-11-19 23:47:16.400 HKT >CONTEXT: SQL statement "create temporary table prestoresult ( "?column?" unknown, "?column?" unknown, "?column?__" unknown )" PL/Python function "run_system_catalog_as_temptable" < 2014-11-19 23:47:16.400 HKT >WARNING: column "?column?" has type "unknown" < 2014-11-19 23:47:16.400 HKT >DETAIL: Proceeding with relation creation anyway. < 2014-11-19 23:47:16.400 HKT >CONTEXT: SQL statement "create temporary table prestoresult ( "?column?" unknown, "?column?" unknown, "?column?" unknown )" PL/Python function "run_system_catalog_as_temp_table" < 2014-11-19 23:47:16.400 HKT >WARNING: column "?column?" has type "unknown" < 2014-11-19 23:47:16.400 HKT >DETAIL: Proceeding with relation creation anyway. < 2014-11-19 23:47:16.400 HKT >CONTEXT: SQL statement "create temporary table prestoresult ( "?column?" unknown, "?column?" unknown, "?column?" unknown )" PL/Python function "run_system_catalog_as_temptable" < 2014-11-19 23:47:33.057 HKT >FATAL: database "default" does not exist < 2014-11-19 23:49:05.434 HKT >FATAL: database "default" does not exist < 2014-11-19 23:50:35.302 HKT >WARNING: Result column "?column?" is renamed to "?column?" because the name appears twice in a query result < 2014-11-19 23:50:35.302 HKT >CONTEXT: PL/Python function "run_system_catalog_as_temp_table" < 2014-11-19 23:50:35.302 HKT >WARNING: Result column "?column?" is renamed to "?column?" because the name appears twice in a query result < 2014-11-19 23:50:35.302 HKT >CONTEXT: PL/Python function "run_system_catalog_as_temp_table" < 2014-11-19 23:50:35.302 HKT >WARNING: column "?column?" has type "unknown" < 2014-11-19 23:50:35.302 HKT >DETAIL: Proceeding with relation creation anyway. < 2014-11-19 23:50:35.302 HKT >CONTEXT: SQL statement "create temporary table prestoresult ( "?column?" unknown, "?column?" unknown, "?column?__" unknown )" PL/Python function "run_system_catalog_as_temptable" < 2014-11-19 23:50:35.302 HKT >WARNING: column "?column?" has type "unknown" < 2014-11-19 23:50:35.302 HKT >DETAIL: Proceeding with relation creation anyway. < 2014-11-19 23:50:35.302 HKT >CONTEXT: SQL statement "create temporary table prestoresult ( "?column?" unknown, "?column?" unknown, "?column?" unknown )" PL/Python function "run_system_catalog_as_temp_table" < 2014-11-19 23:50:35.302 HKT >WARNING: column "?column?" has type "unknown" < 2014-11-19 23:50:35.302 HKT >DETAIL: Proceeding with relation creation anyway. < 2014-11-19 23:50:35.302 HKT >CONTEXT: SQL statement "create temporary table prestoresult ( "?column?" unknown, "?column?" unknown, "?column?" unknown )" PL/Python function "run_system_catalog_as_temp_table"

frsyuki commented 10 years ago

Oh, I haven't tested with Tableau 8.2. I tested only with Tableau 8.1 + Windows 8. Apparently, tableau ran a query to get 3 constants (like "SELECT 1, 2, 3") and ends up with 3 "?column?" an unknown error.

frsyuki commented 9 years ago

I released Prestogres v0.5.0 which includes significant change around query rewriting mechanism. I haven't found time to check compatibility with Tableau 8.2 but hopefully getting list of tables works at least.

frsyuki commented 9 years ago

I confirmed that Tableau 8.3 on Windows 8 works with Prestogres v0.5.3.