Please explain SELECT FROM WHERE IN()
Posted on 2005-04-11
Here is what I have.
I have an ASP form that calls info from a SQL db. This then is posted to a web page in the form of a list with images, check boxes and IDs.
On that page, I select, oh let's say 3 of the 4 checkboxes. I then click the submit button and I want those 3 of 4 items displayed onto the next web page.
Here is the results before I need to post it to the 3rd page.
SELECT * FROM PhotoDB WHERE PhotoID IN('234,235,236')
I need to be able to loop through each of the three ID's and pull their info from the DB.
Here is my idea for the 3rd page:
<%While Not RS.EOF%>
<img border="0" src="<%=(RS("Filename"))%>"></td>
<td width="200"><input type="checkbox" name="order" value="ON"></td>
I want to try here since it is mostly a SQL question, then I will try the ASP forums.