home / sakila

payment

20 rows where customer_id = 428

✎ View and edit SQL

This data as json, xlsx, CSV (advanced)

Suggested facets: staff_id, amount, payment_date (date), last_update (date)

payment_id ▼ customer_id staff_id rental_id amount payment_date last_update
11557 428 428 2 2 634 634 4.99 2005-05-28 17:40:35.000 2020-12-23 07:21:54
11558 428 428 1 1 1227 1227 3.99 2005-06-15 03:50:03.000 2020-12-23 07:21:54
11559 428 428 2 2 1471 1471 2.99 2005-06-15 20:53:26.000 2020-12-23 07:21:54
11560 428 428 1 1 1601 1601 3.99 2005-06-16 06:11:13.000 2020-12-23 07:21:54
11561 428 428 1 1 2677 2677 2.99 2005-06-19 12:01:59.000 2020-12-23 07:21:54
11562 428 428 2 2 3377 3377 0.99 2005-06-21 13:51:12.000 2020-12-23 07:21:54
11563 428 428 1 1 3702 3702 2.99 2005-07-06 10:13:56.000 2020-12-23 07:21:54
11564 428 428 1 1 3925 3925 5.99 2005-07-06 20:41:44.000 2020-12-23 07:21:54
11565 428 428 1 1 4151 4151 0.99 2005-07-07 08:49:02.000 2020-12-23 07:21:54
11566 428 428 1 1 5373 5373 4.99 2005-07-09 18:48:57.000 2020-12-23 07:21:54
11567 428 428 1 1 6735 6735 5.99 2005-07-12 14:08:20.000 2020-12-23 07:21:54
11568 428 428 1 1 7823 7823 6.99 2005-07-28 08:32:53.000 2020-12-23 07:21:54
11569 428 428 1 1 8155 8155 2.99 2005-07-28 20:57:06.000 2020-12-23 07:21:54
11570 428 428 2 2 8387 8387 4.99 2005-07-29 05:47:27.000 2020-12-23 07:21:54
11571 428 428 2 2 8528 8528 4.99 2005-07-29 10:24:22.000 2020-12-23 07:21:54
11572 428 428 1 1 9904 9904 5.99 2005-07-31 14:34:17.000 2020-12-23 07:21:54
11573 428 428 2 2 9982 9982 2.99 2005-07-31 17:09:02.000 2020-12-23 07:21:54
11574 428 428 2 2 10577 10577 4.99 2005-08-01 13:46:38.000 2020-12-23 07:21:54
11575 428 428 2 2 10888 10888 2.99 2005-08-02 00:52:45.000 2020-12-23 07:21:54
11576 428 428 2 2 11536 11536 0.99 2005-08-17 00:40:03.000 2020-12-23 07:21:54

Advanced export

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

CSV options:

CREATE TABLE payment (
  payment_id int NOT NULL,
  customer_id INT  NOT NULL,
  staff_id SMALLINT NOT NULL,
  rental_id INT DEFAULT NULL,
  amount DECIMAL(5,2) NOT NULL,
  payment_date TIMESTAMP NOT NULL,
  last_update TIMESTAMP NOT NULL,
  PRIMARY KEY  (payment_id),
  CONSTRAINT fk_payment_rental FOREIGN KEY (rental_id) REFERENCES rental (rental_id) ON DELETE SET NULL ON UPDATE CASCADE,
  CONSTRAINT fk_payment_customer FOREIGN KEY (customer_id) REFERENCES customer (customer_id) ,
  CONSTRAINT fk_payment_staff FOREIGN KEY (staff_id) REFERENCES staff (staff_id)
);
CREATE INDEX idx_fk_staff_id ON payment(staff_id)
;
CREATE INDEX idx_fk_customer_id ON payment(customer_id)
;
Powered by Datasette · Queries took 9.971ms