I have a long running query because it is reading a very large database. The issue is there is a string of codes that each have an order number. There can be as many as 30 on a line. The order is then matched to another table to get the actual value. What is the best way to loop through this row to get the codes for all of the 20 values. This is an SQL statement.