M
Mettá
The following is a "simple" select distinct query in a form...
<%Dim DSN_NAM33
DSN_Name1 = Application("DB11_ConnectionString")
set Connection = Server.CreateObject("ADODB.Connection")
Connection.Open DSN_NAM33
Set RSCat = Server.CreateObject("ADODB.RecordSet")
SQL = "SELECT DISTINCT County FROM Names ORDER BY County"
RSCat.Open SQL, Connection
%><select name="County" size="1">
<option value="<%=Request("County")%>"><%=Request("County")%></option>
<% while NOT RSCat.EOF %>
<option value="<%=RSCat("County")%>"><%=RSCat("County")%></option>
<%
RSCat.MoveNext
wend
RSCat.Close
%>
Can anyone see anything wrong in this??
Thanks
M
<%Dim DSN_NAM33
DSN_Name1 = Application("DB11_ConnectionString")
set Connection = Server.CreateObject("ADODB.Connection")
Connection.Open DSN_NAM33
Set RSCat = Server.CreateObject("ADODB.RecordSet")
SQL = "SELECT DISTINCT County FROM Names ORDER BY County"
RSCat.Open SQL, Connection
%><select name="County" size="1">
<option value="<%=Request("County")%>"><%=Request("County")%></option>
<% while NOT RSCat.EOF %>
<option value="<%=RSCat("County")%>"><%=RSCat("County")%></option>
<%
RSCat.MoveNext
wend
RSCat.Close
%>
Can anyone see anything wrong in this??
Thanks
M