home / sakila

rental

25 rows where customer_id = 433

✎ 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
146 2005-05-26 00:07:11.000 1431 1431 433 433 2005-06-04 00:20:11.000 2 2 2020-12-23 07:15:22
691 2005-05-29 01:01:26.000 4034 4034 433 433 2005-06-07 06:21:26.000 1 1 2020-12-23 07:15:29
4087 2005-07-07 05:30:56.000 3066 3066 433 433 2005-07-16 10:20:56.000 1 1 2020-12-23 07:16:17
4158 2005-07-07 09:05:42.000 291 291 433 433 2005-07-09 04:28:42.000 1 1 2020-12-23 07:16:18
4988 2005-07-09 00:46:14.000 2718 2718 433 433 2005-07-16 01:45:14.000 2 2 2020-12-23 07:16:30
5457 2005-07-09 22:33:14.000 4179 4179 433 433 2005-07-12 02:30:14.000 1 1 2020-12-23 07:16:37
5969 2005-07-11 00:03:22.000 4177 4177 433 433 2005-07-18 01:28:22.000 2 2 2020-12-23 07:16:45
6765 2005-07-12 15:30:47.000 2571 2571 433 433 2005-07-19 14:19:47.000 2 2 2020-12-23 07:16:56
6848 2005-07-12 19:24:07.000 1782 1782 433 433 2005-07-14 17:03:07.000 1 1 2020-12-23 07:16:57
6850 2005-07-12 19:30:42.000 1145 1145 433 433 2005-07-17 21:26:42.000 2 2 2020-12-23 07:16:57
7821 2005-07-28 08:31:23.000 1184 1184 433 433 2005-08-03 05:08:23.000 2 2 2020-12-23 07:17:12
7907 2005-07-28 11:32:00.000 3252 3252 433 433 2005-07-30 15:27:00.000 1 1 2020-12-23 07:17:13
8414 2005-07-29 06:48:35.000 1337 1337 433 433 2005-08-06 10:54:35.000 2 2 2020-12-23 07:17:21
8713 2005-07-29 17:31:19.000 473 473 433 433 2005-08-02 16:37:19.000 2 2 2020-12-23 07:17:25
9161 2005-07-30 11:19:18.000 969 969 433 433 2005-08-02 05:32:18.000 1 1 2020-12-23 07:17:32
9294 2005-07-30 16:14:37.000 2468 2468 433 433 2005-08-07 18:49:37.000 1 1 2020-12-23 07:17:34
10663 2005-08-01 16:51:08.000 4258 4258 433 433 2005-08-08 21:17:08.000 2 2 2020-12-23 07:17:53
11664 2005-08-17 05:35:52.000 1343 1343 433 433 2005-08-18 02:40:52.000 1 1 2020-12-23 07:18:07
12669 2005-08-18 19:17:47.000 4530 4530 433 433 2005-08-24 14:55:47.000 1 1 2020-12-23 07:18:20
13273 2005-08-19 17:49:13.000 4181 4181 433 433 2005-08-21 14:15:13.000 1 1 2020-12-23 07:18:29
13801 2005-08-20 12:40:53.000 1464 1464 433 433 2005-08-21 16:29:53.000 1 1 2020-12-23 07:18:37
14523 2005-08-21 15:03:45.000 345 345 433 433 2005-08-22 18:06:45.000 2 2 2020-12-23 07:18:48
14559 2005-08-21 16:11:35.000 3842 3842 433 433 2005-08-30 15:26:35.000 1 1 2020-12-23 07:18:49
15476 2005-08-23 01:45:07.000 2478 2478 433 433 2005-08-26 21:07:07.000 2 2 2020-12-23 07:19:02
15502 2005-08-23 02:40:04.000 3219 3219 433 433 2005-08-31 00:36:04.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 12.868ms