Overlapping dates

Hallo everyone

I have a booking table.

Ive tried other solution but ider i selected the wrong thing or i don't know

I have starting date time and ending date time but i need also a filter for the car

I need a formula for the starting date (column De la data Ora) and ending date

Screenshot_20221226-094648_1.png

โ€ƒ

(pana la data ora) to check for the car (column Model) selected that the new dates entered ar not overlapping whit the existing ones

Thanks 

 

 

 

0 1 73
1 REPLY 1

I have found a solution for the moment

I hope that this will not have problems in the future

If someone can confirm that what have i done is right will be much appreciated 

I've changed the keys from Model to start date and end date and it automatically made a computed key

Then ive put this formula in the valid if of start date and end date

Count(filter(Rezervari,AND(([Model] = [_THISROW].[Model]),Not(or(([_this]>=[Pana la Data Ora]),([_this]<=[De la Data Ora]))))))=0

And seams to be working 

Top Labels in this Space