more than likely, your loop logic can be replaced by sql as Mark suggests. Depends on what the requirement is, and how many different ways it can be coded. wihtout actual details in those areas, you are left with a framework of solution-S to your problem and it's up to you to as a hired DBA as to the specific implementation.
↧