Hi all,
i have the following issue which i can not solve. Here is my situation:
3 Tables:
Buchungen (holds bookings of customers for a campsite with lookup to "Plätze" (spaces). Each booking has one space
Plätze ( holds the spaces of the campsite and its characteristics (max vehicle length etc.)
Availiability ( an automated table that creates a record for each day for each site with a yes/no boolean that shows if its available.)
If a booking is made, the booking is entered in BuchungsID via Flow and the available status is set to "No" for all the dates the booking exists. Example: booking is made from april 1st till 3rd on space 1.13 so the in the availability table the respective records have the booking id entered and available set to no.
Now, I am building a visual planner that looks like this:
It holds a nested gallery with a list of the spaces being the outer gallery and the nested one being a collection:
ClearCollect(
CustomDateRangeCollection,
ForAll(
Sequence(varsequence), // Covering the start_date and the next 13 days
{
Date: DateAdd(start_date.SelectedDate, Value - 1, TimeUnit.Days) // Starting from start_date
}
)
);
On the nested gallery I am able to achieve to show the bookings on the right days as shown in the image with the planner using this formula for a label:
IfError(
LookUp(
[@Buchungen],
Anreise <= ThisItem.Date &&
Abreise > ThisItem.Date &&
Platz.Platzname = pname.Text
).Kunde.'Full Name',
""
)This is obviously a perfomance eating task and therefore and for easily determine if spaces are available for multiple days in a row i created the availability table. now i want to use a formula that is easier and checkes the availability table instead of having a lookup to Buchungen (bookings).
I tried this formula below, the formula does not get an error but shows nothing in the planner (see image below)
LookUp(
[@Availabilities],
Datum = ThisItem.Date && PlatzID.Platzname =pname.Text && Available=false
).BuchungsID.BuchungsnummerI am hoping to achieve better performance like this but its weird how is not showing anything.
If i remove the date from the formula i get this below:
Any help is highly appreciated.


Report
All responses (
Answers (