home / sakila

rental

26 rows where customer_id = 208

✎ View and edit SQL

This data as json, xlsx, CSV (advanced)

Suggested facets: rental_date, 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
100 2005-05-25 16:50:28.000 2599 2599 208 208 2005-06-02 22:11:28.000 1 1 2020-12-23 07:15:21
1805 2005-06-16 20:36:00.000 3962 3962 208 208 2005-06-17 16:27:00.000 1 1 2020-12-23 07:15:44
1949 2005-06-17 08:19:22.000 1478 1478 208 208 2005-06-25 08:43:22.000 1 1 2020-12-23 07:15:46
2592 2005-06-19 05:36:54.000 282 282 208 208 2005-06-21 08:44:54.000 1 1 2020-12-23 07:15:55
2695 2005-06-19 13:25:53.000 190 190 208 208 2005-06-24 17:12:53.000 2 2 2020-12-23 07:15:57
2907 2005-06-20 03:15:09.000 2516 2516 208 208 2005-06-20 21:56:09.000 2 2 2020-12-23 07:15:59
3811 2005-07-06 15:20:37.000 695 695 208 208 2005-07-08 16:26:37.000 2 2 2020-12-23 07:16:13
4354 2005-07-07 19:21:02.000 4423 4423 208 208 2005-07-15 17:03:02.000 2 2 2020-12-23 07:16:21
4985 2005-07-09 00:36:02.000 2146 2146 208 208 2005-07-14 04:06:02.000 2 2 2020-12-23 07:16:30
5117 2005-07-09 07:11:22.000 2284 2284 208 208 2005-07-15 08:44:22.000 1 1 2020-12-23 07:16:32
5693 2005-07-10 09:35:43.000 2167 2167 208 208 2005-07-12 08:05:43.000 2 2 2020-12-23 07:16:41
6306 2005-07-11 18:04:26.000 486 486 208 208 2005-07-20 14:22:26.000 2 2 2020-12-23 07:16:49
6767 2005-07-12 15:46:55.000 1819 1819 208 208 2005-07-17 17:36:55.000 2 2 2020-12-23 07:16:56
7315 2005-07-27 13:14:56.000 974 974 208 208 2005-08-03 08:44:56.000 2 2 2020-12-23 07:17:04
7861 2005-07-28 10:02:01.000 1781 1781 208 208 2005-08-06 13:17:01.000 1 1 2020-12-23 07:17:12
7984 2005-07-28 14:27:51.000 2893 2893 208 208 2005-08-04 17:34:51.000 1 1 2020-12-23 07:17:14
8742 2005-07-29 18:56:12.000 918 918 208 208 2005-08-03 16:42:12.000 1 1 2020-12-23 07:17:26
9298 2005-07-30 16:27:53.000 2106 2106 208 208 2005-08-07 12:32:53.000 2 2 2020-12-23 07:17:34
9838 2005-07-31 12:18:49.000 3866 3866 208 208 2005-08-03 16:49:49.000 2 2 2020-12-23 07:17:42
10762 2005-08-01 20:28:39.000 1363 1363 208 208 2005-08-05 17:36:39.000 1 1 2020-12-23 07:17:54
10784 2005-08-01 21:24:28.000 3494 3494 208 208 2005-08-09 19:23:28.000 1 1 2020-12-23 07:17:55
11442 2005-08-02 20:26:19.000 2598 2598 208 208 2005-08-07 00:33:19.000 2 2 2020-12-23 07:18:04
11805 2005-08-17 11:48:47.000 1208 1208 208 208 2005-08-26 11:06:47.000 2 2 2020-12-23 07:18:09
11819 2005-08-17 12:25:17.000 656 656 208 208 2005-08-19 16:12:17.000 1 1 2020-12-23 07:18:09
13719 2006-02-14 15:16:03.000 3547 3547 208 208   1 1 2020-12-23 07:18:36
15717 2006-02-14 15:16:03.000 902 902 208 208   2 2 2020-12-23 07:19:05

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 12.431ms