Forum Discussion
Filtering multiple tables with multiple common filters
Hello!
I'm struggling with using common filters for multiple tables.
I'm currently working with 3 tables, they all have the following format:
| Id | Date | Location |
| 1 | D1 | A |
| 2 | D2 | A |
| 3 | D3 | B |
| 4 | D4 | B |
| 5 | D5 | C |
| 6 | D6 | D |
I need to make multiple visualizations with options to filter via Location and Date
My 1st attempt was to create a composite key of Date + Location, attached to a Location table that I'll use for the Location filtering, and a Date table that I'll use for Date Filtering. Something like this:
However the filter is not working as it should, and many records are missing in my visualizations.
My 2nd attempt was to join the 3 tables, since the IDs and locations are the same for all 3 tables, with 3 distinct dates for each pair:
| Id | Date1 | Date2 | Date3 | Location |
| 1 | D1 | D2 | D3 | a |
| 2 | D4 | D5 | D6 | b |
| 3 | D7 | D8 | D9 | a |
| 4 | D10 | D11 | D12 | b |
| 5 | D13 | D14 | D15 | c |
But that only allows me to use date filtering on one of the 3 dates, and I need to filter the 3 of them independently. I can only have one active relationship with my Date table at all times, and that is getting in the way.
Every date associated with an ID means a different phase in my context, and my visualizations need to count the number of IDs on that each phase on each period.
How can I do this?
Thank you for the help.
1 Reply
- parry2kSuper User
Anonymous not sure why you have [date location] bridge table in between, just connect all your 3 tables directly wiht location and date, and filtering location and date will filter all these 3 tables.