% marca = trim(request("slMarca"))
fatto = request("fatto")
if fatto = 1 then
Dim con, rs, strSql
'Connect to the database
Set con = GetDBConnection()
'Verify that the email address does not already exist in the database
Set rs = Server.CreateObject("ADODB.Recordset")
if marca = "Tutte" then
strSql = "SELECT * FROM Autovettura ORDER BY Marca, Modello"
else
strSql = "SELECT * FROM Autovettura WHERE Marca = '" & marca & "' ORDER BY Marca, Modello"
end if
rs.Open strSql, con, 2, 2
dim cont
cont = 0
do while not rs.eof
cont = cont + 1
rs.movenext
loop
end if
if cont > 0 then
rs.movefirst
end if %>