Forums
This topic is locked
request.query string to SQL statement
Posted 15 Aug 2003 17:46:12
1
has voted
15 Aug 2003 17:46:12 Kevin Sherrard posted:
I got this code working fine but I want to transfer it into the Recordset (Query) in Bindings tab. I can't seem to figure it out can anyone give me some advice. I think it is because of the way I am passing the Section_ID value into the SQL Statement.<%
set conn = server.createObject("ADODB.Connection"

Section_ID=Request.QueryString("Section_ID"

%>
<!-- #include file="conn.asp" -->
<% set rs_vendor = conn.execute("SELECT * FROM Section_Vendor INNER JOIN Vendor ON Section_Vendor.Vendor_ID = Vendor.Vendor_ID WHERE Section_Vendor.Section_ID = " & Section_ID)
do until rs_vendor.eof
%>
<a href="category.asp?Section_ID=<%response.write Section_ID%>&Vendor_ID=<%=rs_vendor("Vendor_ID"


<%
rs_vendor.movenext
loop
%>