Hey All,
Iโd like to add a filter condition to an existing slice.
It should filter the Parent table (that Iโm slicing), based on a value in a field from the Child table.
The relationship: There can be Zero or One Child per Parent.
The tables are:
Parent: turtle_interaction (with PK - interaction_id)
Child: turtle_admission (with FK = interaction_id, and filter condition field = trc_outcome)
Requirement: The Slice should provide only the turtle_interaction records that have associated turtle_admission records with trc_outcome = NULL (blank)
In the App, the Referenced Child Table List is called:
Related dbo.turtle_admissions
Hereโs my expression attempt, that isnโt quite working:
AND([interaction_date_time] > โ01/06/2020 00:00:00โ ,([interaction_outcome] = 2), (ISBLANK(โRelated dbo.turtle_admissionsโ.[trc_outcome])))
Thanks!
Your expression should probably be:
AND(
([interaction_date_time] > โ01/06/2020 00:00:00โ),
([interaction_outcome] = 2),
ISBLANK([Related dbo.turtle_admissions][trc_outcome] - LIST(""))
)
[Related dbo.turtle_admissions][trc_outcome]
is a list dereference. See Constructing a List from a List Dereference here:
A list dereference produces a list. - LIST("")
removes any blank elements from the list. See Constructing a List with Subtraction also in the above doc.
Thank you so much @Steve.
Unfortunately, this doesnโt work either. The filter condition seems to check if thereโs ANY child record. Not only for a child record with NULL value for a specific field.
Any other thoughts?
Hi @Steve, I celebrated too early. Could you please take another look at the formula and help me understand why it might not be working?
The expression I gave you should meet your needs as I understand them from your original description. Unfortunately, your use of database terms instead of AppSheet terms may be confusing me. Could you restate the problem in AppSheet terms or in plain language, rather than database terms?
User | Count |
---|---|
15 | |
10 | |
9 | |
7 | |
3 |