0

I have a fact table that has several dimension keys from the same dimension like a sales_fact with customer_key, manager_key or sales_rep_key all coming from the party_dimension.

... and the join keys are different party_dimension.party_key = sales_fact.customer_key, party_dimension.party_key = sales_fact.manager_key, party_dimension.party_key = sales_fact.sales_rep_key the only option I see is to create three different logical data source for party_dimension and then join to the sales fact.

I would prefer to pull the party_dimension in the data source once for performance sake and perform lookups against the same source... not sure if that's possible in tableau.

Just to give you guys a background we now have a view that joins the fact table with all the relevant dimension tables and the query performance has been not very good. The user needs to await 5-10 mins before the data is fetched... all the proper indexes have been defined between the tables amongst the join keys. That's why we decided to get the tables separately and define the joins within tableau and the thought process is that tableau may cache the relevant logical segments and works the query efficiently.

Venu Family
  • 83
  • 1
  • 4
  • This is the use case for a table alias -- and yes, you join the same table several times. Relational databases are MEANT to operate this way. Tableau isn't meant to do the job of a relational database, nor is it meant to outperform a relational database. Tableau is optimized for data visualization, AFTER the data query. – devlin carnate Oct 01 '21 at 20:56
  • Just to give you guys a background we now have a view that joins the fact table with all the relevant dimension tables and the query performance has been not very good. The user needs to await 5-10 mins before the data is fetched... all the proper indexes have been defined between the tables amongst the join keys. That's why we decided to get the tables separately and define the joins within tableau and the thought process is that tableau may cache the relevant logical segments and works the query efficiently. – Venu Family Oct 03 '21 at 19:44
  • You should post a question on the [DBA website](https://dba.stackexchange.com/questions) regarding your database performance because 5 - 10 min query time sounds problematic. *Something* isn't right there. You should be resolving that problem and not trying to find a workaround using Tableau. – devlin carnate Oct 04 '21 at 19:25
  • (also, there is more to database performance than indexing, fyi) – devlin carnate Oct 04 '21 at 19:37

0 Answers0