UPDATE billing_invoices SET billing_invoices.paid = 0, billing_invoices.payable = billing_invoices.subtotal WHERE billing_invoices.insurance != 'CASH';
UPDATE billing_invoice_items JOIN billing_invoices ON billing_invoices.id = billing_invoice_items.parent_id SET billing_invoice_items.paid = 0, billing_invoice_items.payable = billing_invoice_items.price WHERE billing_invoices.insurance != 'CASH';