ClickHouse / clickhouse-tableau-connector-jdbc

Tableau connector to ClickHouse using JDBC driver
Apache License 2.0
57 stars 9 forks source link

Errors occurred while trying to load the workbook #33

Closed huahuayu closed 2 years ago

huahuayu commented 2 years ago

Hi, I installed tableau server 3 days ago, and I followed your guideline to install clickhouse connector, it was successful, I can see all the tables. Then I published the data source.

But When I view the data source, and click 'Ask Data', an error occurs:

An unexpected error occurred. If you continue to receive this error please contact your Tableau Server Administrator.

Session ID: AAE38ABA14744FF6B5DE65E623F77330-1:1

TableauException: Errors occurred while trying to load the workbook "/views/ds:db-clickhouse-192_168_6_46". The load was not able to complete successfully.

2022-05-16 05:47:14.737

(YoHlYnyXij7rCQ-oxu7rewAAAXA,1:1)

Would you like to reset the view?

image

You can reproduce by following https://liushiming.cn/article/tableau-server-installation-guide.html#Install_clickhouse_JDBC_driver_for_tableau_server, all steps were logged.

I can also provide the server log files if you need them, please help to check.

P.s. tableau desktop also can't use the connection

image

Env

clickhouse: 22.1.3.7 tableau server: 2022.1.1 clickhouse jdbc driver: 0.3.2-patch7 connector: 0.2.2

yurifal commented 2 years ago

Hi @huahuayu

Could you please make a simple datasource (with just a single small table) in Desktop, publish it (the datasource) to your Server, then open it on Server (Ask Data by default)?

I couldn't reproduce your error in my testbed, but suspect it is the datasource being created / configured (in)correct, that's my suggestion all about.

huahuayu commented 2 years ago

Could you please make a simple datasource (with just a single small table) in Desktop, publish it (the datasource) to your Server, then open it on Server (Ask Data by default)?

This is ok. But if you publish the database rather than the table, then you can reproduce it.

Let me summarize:

  1. You can connect the database in desktop, but you can't publish the database to the server, you can only publish tables one by one. Publish database get error:

image

  1. You can connect the database in server, but the Ask Data get error just as I describe in this issue.

image

  1. Even if I ignore the Ask Data in server(actually it can be turned off), but the big problem is the server-created database connection can't be used in the desktop. Click the data source in desktop get error:

image

  1. The only thing can publish is table, you can reuse the table as a data source, works on both desktop & server. But the limitation is so big. What if I need a table join?
huahuayu commented 2 years ago

The workaround is to use desktop only or server only, create viz directly in the server. The database-level data source can't be shared.

yurifal commented 2 years ago

What do you mean by "The database-level data source" ? I don't get it, sorry. btw you can Join (or Relate) tables when building a datasource, don't you?

huahuayu commented 2 years ago

Means you can not publish a database(with all the tables inside it) as data source, you can only publish tables one by one.

yurifal commented 2 years ago

That's correct, the datasource in Tableau has to be made of at least one table -- either "physical" or "logical" one, the latter is the Tableau's Data Model object.

You may talk about Virtual Connections (new in Tableau version 2021.4), but they could be created for limited number of DBMSes (CH is not in the list). And even with Virtual Connection, the datasource has to be made (starting with a table).

yurifal commented 2 years ago

The resume: Tableau cannot utilise a database schema (tablespace) as a datasource.

huahuayu commented 2 years ago

But why I can save such a data source which I don't select a specific table. Next time I open it, I can see all the tables not just 1 table.

yurifal commented 2 years ago

? Could you please share the screen (the Data Source tab, and the Worksheet one) ?

huahuayu commented 2 years ago

image

First let's leave the viz/workbook alone.

After I successfully connected to clickhouse, I want to publish its data connection as a data source to the server, so everyone can share it, but I can't.

image

yurifal commented 2 years ago

This is not the workbook you can publish to a Tableau Server ;-) It doesn't contain a valid datasource (as indicated on the Sheet 1 tab view):

Screenshot 2022-05-16 at 14 32 30
huahuayu commented 2 years ago

ok, so I must create a workbook so that I can publish a data source? That's strange...if so I have no problem.

yurifal commented 2 years ago

I want to publish its data connection as a data source

unfortunately, you can't do this (with any data connection, not just the CH one).

yurifal commented 2 years ago

so I must create a workbook so that I can publish a data source?

You have to create a valid datasource (consisting of at least one table), then you'd be able to publish it to a Server.

yurifal commented 2 years ago

Virtual Connection could be your best friend in the future, but now it's not.

huahuayu commented 2 years ago

Thanks @yurifal I see

huahuayu commented 2 years ago

Virtual Connection could be your best friend in the future, but now it's not.

When it is available?

yurifal commented 2 years ago

Virtual Connection could be your best friend in the future, but now it's not.

When it is available?

Dunno, sorry. It is very uncommon for Tableau to announce schedules for minor enhancements.