home / sakila

rental

45 rows where customer_id = 526

✎ View and edit SQL

This data as json, xlsx, CSV (advanced)

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

rental_id ▼ rental_date inventory_id customer_id return_date staff_id last_update
495 2005-05-28 00:40:48.000 1007 1007 526 526 2005-05-29 06:07:48.000 1 1 2020-12-23 07:15:26
679 2005-05-28 23:24:57.000 907 907 526 526 2005-06-06 21:59:57.000 2 2 2020-12-23 07:15:28
1015 2005-05-31 02:44:57.000 3702 3702 526 526 2005-06-07 23:01:57.000 2 2 2020-12-23 07:15:33
1255 2005-06-15 06:13:45.000 1433 1433 526 526 2005-06-16 03:59:45.000 2 2 2020-12-23 07:15:36
1848 2005-06-17 00:07:07.000 3797 3797 526 526 2005-06-21 21:41:07.000 2 2 2020-12-23 07:15:44
1865 2005-06-17 01:49:36.000 2657 2657 526 526 2005-06-23 21:13:36.000 1 1 2020-12-23 07:15:45
1972 2005-06-17 09:25:49.000 2758 2758 526 526 2005-06-24 09:59:49.000 2 2 2020-12-23 07:15:46
1981 2005-06-17 10:03:34.000 3186 3186 526 526 2005-06-20 13:14:34.000 2 2 2020-12-23 07:15:46
2398 2005-06-18 15:56:53.000 3001 3001 526 526 2005-06-27 14:25:53.000 2 2 2020-12-23 07:15:52
2828 2005-06-19 20:51:33.000 3230 3230 526 526 2005-06-25 17:38:33.000 1 1 2020-12-23 07:15:58
2932 2005-06-20 04:51:19.000 4418 4418 526 526 2005-06-29 08:31:19.000 1 1 2020-12-23 07:16:00
3339 2005-06-21 10:37:11.000 312 312 526 526 2005-06-30 05:04:11.000 2 2 2020-12-23 07:16:05
3619 2005-07-06 05:59:44.000 3350 3350 526 526 2005-07-11 08:58:44.000 2 2 2020-12-23 07:16:10
3905 2005-07-06 19:33:34.000 3817 3817 526 526 2005-07-15 17:55:34.000 1 1 2020-12-23 07:16:14
4423 2005-07-07 22:11:28.000 2721 2721 526 526 2005-07-14 18:49:28.000 2 2 2020-12-23 07:16:22
5056 2005-07-09 04:13:45.000 2599 2599 526 526 2005-07-10 06:17:45.000 2 2 2020-12-23 07:16:31
5121 2005-07-09 07:18:31.000 3321 3321 526 526 2005-07-15 01:48:31.000 1 1 2020-12-23 07:16:32
6316 2005-07-11 18:44:52.000 1910 1910 526 526 2005-07-19 23:35:52.000 2 2 2020-12-23 07:16:49
6404 2005-07-11 22:49:50.000 1183 1183 526 526 2005-07-14 18:29:50.000 2 2 2020-12-23 07:16:51
6650 2005-07-12 10:57:10.000 1589 1589 526 526 2005-07-14 07:24:10.000 1 1 2020-12-23 07:16:54
6671 2005-07-12 11:48:48.000 955 955 526 526 2005-07-19 16:55:48.000 2 2 2020-12-23 07:16:55
7270 2005-07-27 11:29:02.000 1888 1888 526 526 2005-08-05 08:04:02.000 1 1 2020-12-23 07:17:04
7343 2005-07-27 14:27:13.000 1177 1177 526 526 2005-07-30 09:27:13.000 2 2 2020-12-23 07:17:05
7399 2005-07-27 16:16:02.000 1682 1682 526 526 2005-08-03 18:02:02.000 2 2 2020-12-23 07:17:06
7543 2005-07-27 21:44:28.000 1289 1289 526 526 2005-08-04 21:42:28.000 2 2 2020-12-23 07:17:08
7883 2005-07-28 10:37:20.000 447 447 526 526 2005-08-02 05:08:20.000 1 1 2020-12-23 07:17:13
8053 2005-07-28 16:59:41.000 1511 1511 526 526 2005-08-03 22:28:41.000 2 2 2020-12-23 07:17:15
8232 2005-07-29 00:14:37.000 3255 3255 526 526 2005-08-06 00:57:37.000 1 1 2020-12-23 07:17:18
8441 2005-07-29 07:33:05.000 1000 1000 526 526 2005-08-04 04:00:05.000 2 2 2020-12-23 07:17:21
9577 2005-07-31 02:53:33.000 2423 2423 526 526 2005-08-07 05:56:33.000 1 1 2020-12-23 07:17:38
10020 2005-07-31 18:21:08.000 302 302 526 526 2005-08-02 14:03:08.000 2 2 2020-12-23 07:17:44
10199 2005-08-01 00:38:55.000 3665 3665 526 526 2005-08-05 03:41:55.000 1 1 2020-12-23 07:17:46
11046 2005-08-02 06:08:34.000 2105 2105 526 526 2005-08-06 08:45:34.000 2 2 2020-12-23 07:17:58
11503 2005-08-16 23:10:34.000 1496 1496 526 526 2005-08-25 03:55:34.000 1 1 2020-12-23 07:18:05
11612 2005-08-17 03:48:51.000 375 375 526 526 2005-08-20 03:03:51.000 1 1 2020-12-23 07:18:06
11702 2005-08-17 07:18:56.000 3286 3286 526 526 2005-08-24 06:33:56.000 1 1 2020-12-23 07:18:07
12607 2005-08-18 17:03:49.000 2130 2130 526 526 2005-08-19 18:29:49.000 1 1 2020-12-23 07:18:19
13224 2005-08-19 15:52:13.000 3086 3086 526 526 2005-08-28 20:53:13.000 2 2 2020-12-23 07:18:29
13580 2005-08-20 05:23:34.000 4419 4419 526 526 2005-08-23 02:45:34.000 1 1 2020-12-23 07:18:34
13617 2005-08-20 06:35:30.000 4059 4059 526 526 2005-08-29 09:03:30.000 1 1 2020-12-23 07:18:35
14487 2005-08-21 13:53:33.000 2578 2578 526 526 2005-08-29 19:32:33.000 1 1 2020-12-23 07:18:48
14590 2005-08-21 17:29:10.000 2633 2633 526 526 2005-08-28 20:15:10.000 1 1 2020-12-23 07:18:49
15168 2005-08-22 15:14:20.000 3218 3218 526 526 2005-08-25 20:12:20.000 2 2 2020-12-23 07:18:57
15395 2005-08-22 23:06:25.000 2880 2880 526 526 2005-08-30 19:18:25.000 1 1 2020-12-23 07:19:01
16043 2005-08-23 22:21:03.000 3869 3869 526 526 2005-08-31 03:09:03.000 2 2 2020-12-23 07:19:10

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