home / sakila

rental

22 rows where customer_id = 68

✎ View and edit SQL

This data as json, xlsx, CSV (advanced)

Suggested facets: staff_id, last_update, rental_date (date), return_date (date), last_update (date)

rental_id ▼ rental_date inventory_id customer_id return_date staff_id last_update
1828 2005-06-16 22:04:34.000 316 316 68 68 2005-06-20 21:07:34.000 2 2 2020-12-23 07:15:44
1957 2005-06-17 08:50:58.000 2496 2496 68 68 2005-06-26 13:39:58.000 2 2 2020-12-23 07:15:46
2633 2005-06-19 08:53:10.000 3462 3462 68 68 2005-06-20 07:56:10.000 1 1 2020-12-23 07:15:56
2662 2005-06-19 10:53:42.000 3936 3936 68 68 2005-06-20 11:41:42.000 1 1 2020-12-23 07:15:56
2686 2005-06-19 12:44:20.000 2686 2686 68 68 2005-06-20 16:00:20.000 1 1 2020-12-23 07:15:57
3598 2005-07-06 05:11:04.000 1317 1317 68 68 2005-07-09 02:03:04.000 2 2 2020-12-23 07:16:09
3801 2005-07-06 15:05:50.000 4209 4209 68 68 2005-07-12 12:56:50.000 1 1 2020-12-23 07:16:12
3864 2005-07-06 17:41:42.000 2811 2811 68 68 2005-07-08 14:17:42.000 1 1 2020-12-23 07:16:13
4555 2005-07-08 04:48:36.000 1757 1757 68 68 2005-07-17 07:57:36.000 1 1 2020-12-23 07:16:24
4925 2005-07-08 21:56:00.000 2169 2169 68 68 2005-07-14 17:17:00.000 2 2 2020-12-23 07:16:29
6512 2005-07-12 03:42:49.000 1703 1703 68 68 2005-07-13 05:01:49.000 2 2 2020-12-23 07:16:52
9339 2005-07-30 18:03:28.000 3171 3171 68 68 2005-08-08 19:45:28.000 2 2 2020-12-23 07:17:34
9538 2005-07-31 01:25:22.000 3402 3402 68 68 2005-08-06 00:10:22.000 2 2 2020-12-23 07:17:37
9642 2005-07-31 05:33:57.000 3550 3550 68 68 2005-08-05 04:54:57.000 1 1 2020-12-23 07:17:38
10115 2005-07-31 21:13:47.000 2731 2731 68 68 2005-08-10 00:44:47.000 1 1 2020-12-23 07:17:45
11277 2005-08-02 14:28:50.000 2050 2050 68 68 2005-08-04 13:50:50.000 1 1 2020-12-23 07:18:01
12742 2005-08-18 22:22:03.000 1742 1742 68 68 2005-08-22 04:01:03.000 1 1 2020-12-23 07:18:21
13475 2005-08-20 01:05:05.000 3214 3214 68 68 2005-08-20 20:22:05.000 2 2 2020-12-23 07:18:32
14242 2005-08-21 05:25:59.000 1588 1588 68 68 2005-08-27 07:22:59.000 1 1 2020-12-23 07:18:44
14455 2005-08-21 12:36:11.000 3442 3442 68 68 2005-08-27 08:12:11.000 2 2 2020-12-23 07:18:47
14947 2005-08-22 06:07:52.000 3497 3497 68 68 2005-08-28 01:12:52.000 2 2 2020-12-23 07:18:54
15524 2005-08-23 03:36:26.000 2886 2886 68 68 2005-08-26 06:28:26.000 2 2 2020-12-23 07:19:02

Advanced export

JSON shape: default, array, newline-delimited, object

CSV options:

CREATE TABLE rental (
  rental_id INT NOT NULL,
  rental_date TIMESTAMP NOT NULL,
  inventory_id INT  NOT NULL,
  customer_id INT  NOT NULL,
  return_date TIMESTAMP DEFAULT NULL,
  staff_id SMALLINT  NOT NULL,
  last_update TIMESTAMP NOT NULL,
  PRIMARY KEY (rental_id),
  CONSTRAINT fk_rental_staff FOREIGN KEY (staff_id) REFERENCES staff (staff_id) ,
  CONSTRAINT fk_rental_inventory FOREIGN KEY (inventory_id) REFERENCES inventory (inventory_id) ,
  CONSTRAINT fk_rental_customer FOREIGN KEY (customer_id) REFERENCES customer (customer_id)
);
CREATE INDEX idx_rental_fk_inventory_id ON rental(inventory_id)
;
CREATE INDEX idx_rental_fk_customer_id ON rental(customer_id)
;
CREATE INDEX idx_rental_fk_staff_id ON rental(staff_id)
;
CREATE UNIQUE INDEX idx_rental_uq  ON rental (rental_date,inventory_id,customer_id)
;
Powered by Datasette · Queries took 11.809ms