Re: Overlapping timestamptz ranges with priority - Mailing list pgsql-general

From Adrian Klaver
Subject Re: Overlapping timestamptz ranges with priority
Date
Msg-id 5e7b07f6-5bc7-a0e7-86af-04a63c117764@aklaver.com
Whole thread Raw
In response to Re: Overlapping timestamptz ranges with priority  (Ray O'Donnell <ray@rodonnell.ie>)
Responses Re: Overlapping timestamptz ranges with priority  (Ray O'Donnell <ray@rodonnell.ie>)
List pgsql-general
On 6/29/21 2:30 PM, Ray O'Donnell wrote:
> On 29/06/2021 22:10, Adrian Klaver wrote:
>>
>> The queued bookings are for a particular aircraft or a particular time 
>> slot?
> 
> They're for an aircraft. On the old system, they could only be for a 
> slot - so if someone had booked, say, a two-hour slot, then anyone 
> queued behind them could only queue for the same two hours. I'd like to 
> make the new system more flexible, hence the potentially overlapping 
> ranges.

If I'm following correctly then:

1) Under old system there where preset two hour slots over a day period, 
where the period was say 8:00 to 16:00

2) You now want to allow user defined two hour slots over the same 
period, where a slot can't start before 8:00 or end after 16:00.

3) First to file gets the slot.

4) Because of turn around considerations a user can't pick up the 
remaining hour of an overlap. As example in the case of time slots of 
10:00 - 12:00 and 11:00 - 13:00 for a particular plane where the second 
slot was the later one filed the user can't get 12:00 - 13:00.



> 
> Ray.
> 


-- 
Adrian Klaver
adrian.klaver@aklaver.com



pgsql-general by date:

Previous
From: Ray O'Donnell
Date:
Subject: Re: Overlapping timestamptz ranges with priority
Next
From: Yi Sun
Date:
Subject: postgresql version 13 repo question