home / sakila

rental

29 rows where customer_id = 448

✎ 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
299 2005-05-26 20:55:36.000 4376 4376 448 448 2005-05-28 00:25:36.000 2 2 2020-12-23 07:15:24
1123 2005-05-31 16:48:43.000 142 142 448 448 2005-06-02 19:17:43.000 2 2 2020-12-23 07:15:35
1313 2005-06-15 10:18:34.000 1657 1657 448 448 2005-06-23 06:25:34.000 1 1 2020-12-23 07:15:37
1823 2005-06-16 21:48:16.000 3871 3871 448 448 2005-06-22 03:09:16.000 1 1 2020-12-23 07:15:44
2697 2005-06-19 13:29:08.000 2271 2271 448 448 2005-06-23 13:21:08.000 1 1 2020-12-23 07:15:57
3225 2005-06-21 02:16:55.000 1003 1003 448 448 2005-06-27 05:39:55.000 2 2 2020-12-23 07:16:04
3347 2005-06-21 11:08:32.000 4330 4330 448 448 2005-06-28 09:59:32.000 1 1 2020-12-23 07:16:06
3959 2005-07-06 22:07:58.000 40 40 448 448 2005-07-13 02:30:58.000 1 1 2020-12-23 07:16:15
3992 2005-07-06 23:36:56.000 3219 3219 448 448 2005-07-15 03:13:56.000 1 1 2020-12-23 07:16:15
4024 2005-07-07 02:11:23.000 3976 3976 448 448 2005-07-11 02:00:23.000 1 1 2020-12-23 07:16:16
4206 2005-07-07 11:32:16.000 1557 1557 448 448 2005-07-14 13:07:16.000 2 2 2020-12-23 07:16:19
4406 2005-07-07 21:35:16.000 438 438 448 448 2005-07-15 16:13:16.000 2 2 2020-12-23 07:16:22
4537 2005-07-08 03:48:40.000 1305 1305 448 448 2005-07-13 22:54:40.000 2 2 2020-12-23 07:16:24
4558 2005-07-08 04:55:26.000 828 828 448 448 2005-07-09 10:53:26.000 2 2 2020-12-23 07:16:24
6341 2005-07-11 19:48:02.000 3580 3580 448 448 2005-07-15 01:31:02.000 1 1 2020-12-23 07:16:50
6985 2005-07-27 00:57:42.000 1834 1834 448 448 2005-07-31 00:53:42.000 1 1 2020-12-23 07:16:59
9178 2005-07-30 11:58:50.000 2046 2046 448 448 2005-08-08 15:24:50.000 2 2 2020-12-23 07:17:32
11608 2005-08-17 03:36:52.000 1673 1673 448 448 2005-08-25 07:17:52.000 2 2 2020-12-23 07:18:06
11798 2005-08-17 11:21:43.000 3974 3974 448 448 2005-08-25 07:43:43.000 2 2 2020-12-23 07:18:09
12446 2005-08-18 10:56:29.000 2138 2138 448 448 2005-08-23 05:30:29.000 1 1 2020-12-23 07:18:17
13220 2005-08-19 15:42:32.000 1017 1017 448 448 2005-08-25 13:37:32.000 1 1 2020-12-23 07:18:29
13250 2005-08-19 16:47:55.000 2524 2524 448 448 2005-08-26 16:54:55.000 2 2 2020-12-23 07:18:29
13577 2006-02-14 15:16:03.000 3844 3844 448 448   2 2 2020-12-23 07:18:34
13982 2005-08-20 19:08:25.000 2901 2901 448 448 2005-08-28 15:59:25.000 2 2 2020-12-23 07:18:40
14580 2005-08-21 16:56:39.000 1440 1440 448 448 2005-08-28 15:25:39.000 1 1 2020-12-23 07:18:49
14711 2005-08-21 21:22:07.000 1973 1973 448 448 2005-08-30 16:24:07.000 2 2 2020-12-23 07:18:51
14734 2006-02-14 15:16:03.000 1369 1369 448 448   2 2 2020-12-23 07:18:51
15358 2005-08-22 21:29:14.000 822 822 448 448 2005-08-31 00:10:14.000 2 2 2020-12-23 07:19:00
15427 2005-08-23 00:07:53.000 2775 2775 448 448 2005-09-01 02:55:53.000 2 2 2020-12-23 07:19:01

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.968ms