Re: How to store opening time of shops?
From: ^Bart <gabriele1NOSPAM_at_hotmail.com>
Date: Tue, 19 Mar 2019 09:53:05 +0100
Message-ID: <q6qalg$m9p$1_at_gioia.aioe.org>
Date: Tue, 19 Mar 2019 09:53:05 +0100
Message-ID: <q6qalg$m9p$1_at_gioia.aioe.org>
> For holidays (or 'other-than-usual-days') you could define an extra
> table which would hold the deviations:
Yes, it's better to say "Other than usual days" because it could happen to see a shop closed in a opened day and vice versa!
> CREATE TABLE holiday (
> storeid INTEGER
> , holiday DATE
> , opened TIME
> , close TIME
> , primary key(storeid, dow, opened)
>
> INSERT INTO schedule (storeid, holiday, opened, close) VALUES
> (123, '2019-12-24', '08:30', '12:30')
Thank you! :)
^Bart
Received on Tue Mar 19 2019 - 09:53:05 CET