delete from jo_event;
delete from invoice_item;
delete from invoice;
delete from ticket;

set foreign_key_checks = 0;
delete from job_order;
delete from customer;
delete from customer_vehicle;
set foreign_key_checks = 1;

update rider set active_jo_id = null;
