Please impart wisdom starting now,
I have a list of .mp3 file names in my database base. I intend to have links to files which are stored on the server. I can successfully create one link to the file, but looping provides a problem, I need advice/ideas on syntax to be included in my sql queries.
here's the code, any ideas appretiated
Gav
<%
Dim oRS3
Set oRS3=Server.CreateObject("adodb.Recordset"
sqlText = "SELECT ArtistNameTable.ArtistName, ArtistNameTable.Style, ArtistNameTable.SongName, ArtistNameTable.Price, ArtistNameTable.MP3Name "
sqlText = sqlText & " FROM ArtistNameTable "
sqlText = sqlText & " WHERE Style='rock' "
sqlText = sqlText & " ORDER by ArtistNameTable.Style;"
oRS3.Open sqlText, "DSN=music"
oRS3.MoveFirst
MP3Name = oRS3("MP3Name".value
Response.Write "<table border=1>"
Do while NOT oRS3.EOF
Response.Write "<tr><td>" & oRS3("Style" & "</td>"
Response.Write "<td>" & oRS3("ArtistName" & "</td>"
Response.Write "<td>" & oRS3("SongName" & "</td>"
Response.Write "<td>" & oRS3("Price" & "</td>"
oRS3.MoveNext
loop
oRS3.Close
Set oRS3=Nothing
%>
''this is the present effort, need to place in reponse write but ASP 'is having none of it'
<td><a href="/_private/images/<%=MP3Name%>">link is hear</a></td></tr>
</table>
</body>
</html>
I have a list of .mp3 file names in my database base. I intend to have links to files which are stored on the server. I can successfully create one link to the file, but looping provides a problem, I need advice/ideas on syntax to be included in my sql queries.
here's the code, any ideas appretiated
Gav
<%
Dim oRS3
Set oRS3=Server.CreateObject("adodb.Recordset"
sqlText = "SELECT ArtistNameTable.ArtistName, ArtistNameTable.Style, ArtistNameTable.SongName, ArtistNameTable.Price, ArtistNameTable.MP3Name "
sqlText = sqlText & " FROM ArtistNameTable "
sqlText = sqlText & " WHERE Style='rock' "
sqlText = sqlText & " ORDER by ArtistNameTable.Style;"
oRS3.Open sqlText, "DSN=music"
oRS3.MoveFirst
MP3Name = oRS3("MP3Name".value
Response.Write "<table border=1>"
Do while NOT oRS3.EOF
Response.Write "<tr><td>" & oRS3("Style" & "</td>"
Response.Write "<td>" & oRS3("ArtistName" & "</td>"
Response.Write "<td>" & oRS3("SongName" & "</td>"
Response.Write "<td>" & oRS3("Price" & "</td>"
oRS3.MoveNext
loop
oRS3.Close
Set oRS3=Nothing
%>
''this is the present effort, need to place in reponse write but ASP 'is having none of it'
<td><a href="/_private/images/<%=MP3Name%>">link is hear</a></td></tr>
</table>
</body>
</html>