I can't say that I know exactly what you want to do because it looks like you're trying to build exactly the same string twice, which seems unnecessary. But I think what you have posted above doesn't work because you're doing the query, looping through the results, then trying to loop through them again (which I don't think will work, I think you'd have to perform the query again).
If you want to have more than one select, why not just use the same string of options for both? Or if the options aren't really supposed to be exactly the same, you could build both strings in the same loop.
|