is contextual filtering for databases planned?
would love a solution for this
is contextual filtering for databases planned?
would love a solution for this
Isn’t this just a case of choosing the correct context filter for the Options
And then naturally, if the Options are grouped by Consolidation (and you have Hide Empty Fields enabled for Consolidations) you will only see the relevant Options under their correct Consolidations.
the problem is, I need to apply a contextual filter for Consolidations as well. The options that i am seeing here are correct based on the contextual filter.
When i group them based on Consolidations, it becomes a general grouping i.e. consolidations that are not related to the current option that i am in also show up here.
I have a lookup field which tells which consolidations are the ones related to the current option, so if i can use another contextual filter, use that look up field and anchor it to the current option that i am in, problem solved
Maybe I don’t quite understand.
What are the dbs and relations?
You have Facts, Options and Consolidations, right?
We are looking at an Option entity, right? There is a field called All Correct Options when used as Label (which is a to-many relation to other Options)?
And Options can be linked to multiple Consolidations (via a lookup on the Fact db)?
So you want to show the Options that are linked to this Option, grouped by Consolidation, but you don’t want to show the Consolidations that they are directly linked to, but only the ones that this Option is linked to (indirectly)?
Seems really convoluted…
For example, imagine the following:
Option A → Fact 1, Fact 2
Fact 1 - Consolidation X
Fact 2 - Consolidation Y
Option B → Fact 3
Fact 3 - Consolidation Z
This means Option A has a lookup which gives Consolidation X and Consolidation Y, and Option B has a lookup which gives Consolidation Z
If Option A → Option B then you’re asking for context filters so that Option B will be shown, but only Consolidations X and Y will be shown for the grouping, right?
In which case, you will see nothing useful in that relation field.
What am I missing?
great understanding!
Will add the missing context here.
Consolidations are basically like a Quiz test. They have Labels (Questions) and corresponding Options (Answers). Both Labels and Options are records in the db Options.
They are both supplied by a Fact to a consolidation.
The All Correct Options when used as Label field, is powered by a series of lookups and automations, which basically finds out all the correct answers (Options) corresponding to a Label (Current Option in question) in every Consolidation that the correct option is used as a Label in.
Note that a fact can supply multiple options but only one label, and many facts can supply options to the same label (but a fact can only be linked to a single consolidation)
So we have established that Options can be part of Consolidations in which they are used as Options (answers) and Labels (Questions) separately.
So in my video, I am inside an Option and I want to see all the correct answers for it, when it is used a label.
I successfully have that:
Now, I wish to group it based on the Consolidations (Quizes) that the current option appears as a Label (Question). However, there is no way to filter exactly for that.
I have two available grouping choices for the Options:
However, if i chose 2, it will bring forth all the consolidation that those Options are found in, not just the ones where the current option is used as a Label.
I am beginning to understand, but what does it mean for the example I gave (where the linked Options could disappear if they belong to a non-overlapping set of Consolidations that the Option they are linked to)?
Also, why
?
Seems odd to knowingly put two different types of things (Questions and Answers) in a single database…
Are you saying that a Question is sometimes an Answer?!
In the video, it appears as though the linked Options, belong to various Consolidations, but none are Consolidations that this Option is linked to
Bone Tumour Consolidations as the groups, but they would all be empty (no linked Options inside)?
OK, more context.
Think of this like a game of Match.
In one game, the instruction could be “What are the possible treatment options for this Disease?” and a set of Labels would be Diseases like Brain Tumour, Fracture Pelvis etc.,
In another game, the instruction could be “Which Diseases are common in this Age Group?” where the Label would be Age Group and the Option would be the disease like Brain Tumour,Fracture Pelvis etc.,
So Label and Option fields basically dictate the position in the Game, not really Question and Answer. The question is dictated by the specific instruction for each Consolidation.
This can never be possible in our structure, if we choose the right Consolidation field to group by.
That’s because i mistakenly selected the wrong consolidation field to group by (the below one)
If I choose
then the list would always be inclusive of all the consolidations that the current option is also linked to.
To answer this
Yes, it would all be empty.
While all the linked options would be under “No Consolidations”
Can you provide a screenshot where it shows how it would look if you chose the right grouping option
In general, this contextual filter becomes really powerful in any system where there is a chain of relations like:
Items <> Customer <> Discount Coupon
I am inside Customer and I want to see all the items they bought grouped by Discount coupons used by this customer, not every discount coupon that was used on the item by any customer
I think I get it.
Have you considered using a board view, with the Options as cards, and Consolidations as Rows?
In this case, you can define one context filter for the cards and one for the rows. If you choose the card size as line it will look fairly similar to a list view.
that’s a fantastic start, board view letting me define multiple context filters. However, it is still highly limited:
The limitations:
Support is there until the point where i am able to choose the right relational field to group by, i just want to be able to write a filter like this:
in fact, this is a much cleaner way to handle contextual filters for cases that I mention. We just need a relative option similar to “Today” “Yesterday” etc., but for Entities like “This Enity”
(using the other general example):
I am inside a customer with a relational view to all the Items they purchased and grouped by Discount Coupons used for that item with this filter on Discount Coupons:
Where Items bought with Coupon contains any of Current Entity
If you are familiar with Tana and how it’s Search Nodes (Views with Filters) function, then basically it is similar to the Parent Node option that we can use in the Field Value.

Search nodes give you the power to find anything, anywhere in Tana. They are easy to make, and can exist anywhere you can add a node. The many search operators available put advanced tools in your hands to create very specific searches according to...
Parent Node == Current Entity in which the view is embedded in
- The relational field that i used to group is not the same relational field i want to apply the contextual filter to
- I don’t think a look up field is powerful enough to be used in filters as a first class citizen like a relational field
- The the list of “fields” to select for the contextual filter needs a search bar, it has a zillion options to choose from and the text also gets cut off after a limit
Do you have a lookup in Consolidations to get Options from Facts?
This is the relation that should be used for the context filter on the Consolidations.
Oh wow, it worked.
This is fantastic, thanks! Board view isn’t perfect, but at least this works! This is great, thank you so much @Chr1sG!
Is there any plan to extent the support for contextual filters or introduce the ability to use the “current entity” in filter fields?
Is there any plan to extent the support for contextual filters or introduce the ability to use the “current entity” in filter fields?
Eventually, context filters will be changed so that they behave like a more general filter, and some of the issues you are talking about will disappear. But we don’t have an ETA.
Overall, context filters by definition are always referenced to the ‘current entity’ but as you are experiencing, finding the right path isn’t always intuitive.
Can’t wait for that! Thanks!