drop trigger if exists porder_before_delete;
DELIMITER // 
create trigger porder_before_delete after delete on dbr_porder
    for each row begin
        delete from dbr_porder_bd where porder_id = old.id;
        delete from dbr_purch where porder_id = old.id;
    END//
DELIMITER ;