Skip to content

DuckDB JDBC doesnt seem to work with timestamps in Tableau #7013

@ryanrozich

Description

@ryanrozich

What happens?

I've connected tableau desktop (Mac) to duckdb via 'Other Database (JDBC)' as described here
https://brocktibert.medium.com/use-tableau-to-connect-to-duckdb-e92daad6e7b4

The connection works, and I can see the schema. However when I preview the data I get this error:
image

In tableau workbook I can work with the varchar fields as dimensions, however whenever I try to use the timestamp fields (truncated to some lower granularity like hour or year) I get the following error
image

Are there any known issues with working with timestamps in tableau using the jdbc connector? I am using the SQL92 Postgres dialect in the JDBC datasource setup wizard in tableau. I have also tried setting it up using the Postgres SQL92 dialect, and got a different error in the worksheet when trying to work with the timestamp field.

My duckdb database reads from parquet files stored locally
I am on

  • MacOS 13.3.1
  • duckdb v0.7.1 b00b93f
  • tableau desktop 2023.1

To Reproduce

duckdb database.duckdb
CREATE TABLE f_cj_events_v2 AS SELECT * FROM read_parquet('/path/to/*.parquet');
CHECKPOINT;

(the database needs to include a timestamp field)

(copy duckdb_jdbc-0.7.1 to ~/Library/Tableau/Drivers) MacOS

(in tableau desktop)
Create datasource -> other JDBC -> jdbc:duckdb:///path_to/database.duckdb
Drag the timestamp field to a column, set the granularity to 'Hour'

OS:

MacOS 13.3.1

DuckDB Version:

0.7.1

DuckDB Client:

Tableau (JDBC)

Full Name:

Ryan Rozich

Affiliation:

Self

Have you tried this on the latest master branch?

  • I agree

Have you tried the steps to reproduce? Do they include all relevant data and configuration? Does the issue you report still appear there?

  • I agree

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions