Table
audio_guide_hire
Each hire: ticket, device, language, issuing and returning wing, times and payment.
Replaces in 2020: Hired Audio Guide
Rows 651–675 of 1,085
| hire_idINTEGER | ticket_id→ ticket.ticket_id | serial_number→ audio_guide_device.serial_number | order_id→ purchase_order.order_id | language_code→ language.language_code | issued_wing_id→ wing.wing_id | issued_atTEXT | returned_wing_id→ wing.wing_id | returned_atTEXT |
|---|---|---|---|---|---|---|---|---|
| 651 | 5660 | D332R599Y1992N37 | 3162 | ko | 2 | 2018-04-30 11:20:33 | 1 | 2018-04-30 12:19:23 |
| 652 | 5692 | D332R599Y1992N37 | 3178 | it | 2 | 2018-05-05 09:50:00 | 3 | 2018-05-05 12:09:27 |
| 653 | 5693 | D080D377C3402T31 | 3180 | zh | 2 | 2018-05-05 10:30:09 | 3 | 2018-05-05 11:59:32 |
| 654 | 5698 | D462B968Z1112C56 | 3184 | en | 2 | 2018-05-06 10:06:45 | 2 | 2018-05-06 11:47:03 |
| 655 | 5655 | D558F571V1033X91 | 3185 | en | 2 | 2018-05-06 10:27:40 | 3 | 2018-05-06 12:25:33 |
| 656 | 5756 | D500A274G0533N08 | 3201 | en | 2 | 2018-05-12 16:05:37 | 1 | 2018-05-12 17:21:17 |
| 657 | 5740 | D072X344L7834Y11 | 3204 | en | 2 | 2018-05-13 09:48:59 | 2 | 2018-05-13 11:30:09 |
| 658 | 5759 | D324Z884K8486X42 | 3205 | fr | 1 | 2018-05-13 10:17:09 | 1 | 2018-05-13 11:19:45 |
| 659 | 5753 | D191E591F4947H41 | 3207 | pt | 2 | 2018-05-13 12:22:36 | 2 | 2018-05-13 14:05:46 |
| 660 | 5750 | D724L458C1162U17 | 3208 | pt | 2 | 2018-05-13 12:23:55 | 2 | 2018-05-13 14:53:25 |
| 661 | 5779 | D462B968Z1112C56 | 3217 | en | 1 | 2018-05-15 10:26:15 | 1 | 2018-05-15 12:37:41 |
| 662 | 5747 | D191E591F4947H41 | 3221 | en | 2 | 2018-05-16 11:18:23 | 3 | 2018-05-16 13:10:10 |
| 663 | 5746 | D724L458C1162U17 | 3222 | en | 2 | 2018-05-16 11:28:25 | 1 | 2018-05-16 14:11:43 |
| 664 | 5785 | D663Z129H2049D24 | 3223 | sv | 2 | 2018-05-16 11:50:16 | 3 | 2018-05-16 13:55:48 |
| 665 | 5788 | D724L458C1162U17 | 3226 | zh | 2 | 2018-05-17 11:21:07 | 2 | 2018-05-17 12:22:16 |
| 666 | 5789 | D570K624F8858E76 | 3227 | fr | 2 | 2018-05-17 11:32:55 | 2 | 2018-05-17 12:52:44 |
| 667 | 5767 | D177W168C4167Y04 | 3232 | ru | 2 | 2018-05-18 10:43:25 | 2 | 2018-05-18 13:59:18 |
| 668 | 5764 | D413Q817Y7694B71 | 3233 | ru | 2 | 2018-05-18 10:43:44 | 1 | 2018-05-18 13:30:57 |
| 669 | 5766 | D130X023V8765P41 | 3234 | ru | 2 | 2018-05-18 10:45:06 | 2 | 2018-05-18 12:25:49 |
| 670 | 5765 | D265V521D1968K75 | 3235 | ru | 2 | 2018-05-18 10:49:02 | 2 | 2018-05-18 12:17:31 |
| 671 | 5802 | D127T102L7940A93 | 3242 | en | 2 | 2018-05-19 15:26:44 | 2 | 2018-05-19 16:57:26 |
| 672 | 5681 | D586V966T0652S73 | 3243 | en | 3 | 2018-05-19 16:06:11 | 2 | 2018-05-19 18:10:00 |
| 673 | 5793 | D736D252Z3041D49 | 3248 | it | 2 | 2018-05-21 13:21:57 | 2 | 2018-05-21 15:22:33 |
| 674 | 5577 | D547F386X8659H60 | 3250 | en | 1 | 2018-05-22 11:05:27 | 3 | 2018-05-22 12:52:39 |
| 675 | 5804 | D500A274G0533N08 | 3255 | it | 2 | 2018-05-25 13:35:21 | 2 | 2018-05-25 15:06:21 |
Table definition
CREATE TABLE audio_guide_hire (
hire_id INTEGER PRIMARY KEY,
ticket_id INTEGER NOT NULL REFERENCES ticket (ticket_id),
serial_number TEXT NOT NULL REFERENCES audio_guide_device (serial_number),
order_id INTEGER NOT NULL UNIQUE REFERENCES purchase_order (order_id),
language_code TEXT NOT NULL REFERENCES language (language_code),
issued_wing_id INTEGER NOT NULL REFERENCES wing (wing_id),
issued_at TEXT NOT NULL,
returned_wing_id INTEGER REFERENCES wing (wing_id),
returned_at TEXT,
CHECK ((returned_at IS NULL) = (returned_wing_id IS NULL)),
CHECK (returned_at IS NULL OR returned_at > issued_at)
) STRICT;