Filter view latest of any door.

By: koen Vanraes | Asked: 04/23/2024
ForumsCategory: General questionsFilter view latest of any door.
koen Vanraeskoen Vanraes asked 7 months ago

Hey everyone,
I created a form for checking firedoors.
So they fill in what number of door they are going to chek and they fill in the rest of the form.
At the end the door get a score.
Higher than 10 = direct action, between 5 and 10 = action but not direct. under 5 = door is OK.

So in the database I have following entrys:
id      Numberdoor      score     date
-----------------------------------------------
14     AT3432              13         2024/03/05
15     ZE23E34            12        2024/03/06
16    3E454R2            10         2024/03/15
17    AT3432               5          2024/04/01

I want a View that only if the newest score  of any door that is higher then 10 need to see. So check only the latest entry of each door. So my filter is now "SCORE higher or equal to 10 AND Numberdoor Unique (get newest entries)"

My view looks now like:
AT3432          13
ZE23E34        12
3E454R2        10

Why is AT3432 still showed? There is a newer entry with a lower score....

Can someone help me?

Thanks!!

With kind regards,
Koen

2 Answers
Victor Font answered 7 months ago
What do you have in your view filter? It's entirely possible that the query isn't looking at the full number and is sorting by the first digit, which would make 5 > 1 true.
koen Vanraeskoen Vanraes answered 7 months ago
I took a screenshot of the filter I Use.
Attachments
Bobby Clapp replied 7 months ago

Is the score field a number or text field?

koen Vanraeskoen Vanraes replied 7 months ago

Its a number field

Bobby Clapp replied 7 months ago

Ultimately it is doing what you are asking, but I don't think order of the filter is being honored. Have you submitted the issue to the Formidable support team?

It is finding and only listing the unique value. It is finding and listing a value greater than 10. It is not honoring them as "and" while also in the order in which you have the filters.

Making the Best WordPress Plugin even better - Together

Take on bigger projects with confidence knowing you have access to an entire community of Formidable Experts and Professionals who have your back when the going gets tough. You got this!
Join the community
crossarrow-right