when we are leaving Qatar, we need to clear and close our bank accounts, whether it is active or not. same goes also if your are driving and you have a traffic violations needs to be settled. or even if you borrow a money form your friend(maybe he filed a case on you). you need to be sure that you are really cleared to leave. so just go to the bank and closed it. its better to be sure than you have a unrest feeling while queuing at immigration gate.