Conexão MySQL com ASP Clássico
Altere os campos com suas configurações:localmysql: NOME-DO-BANCO:USUARIO:SENHA
<!doctype html>
<html>
<head>
<meta charset="utf-8">
<title>Conexão MySQL em ASP Clássico</title>
</head>
<body>
</body>
<%
conexao = "DRIVER={MySQL ODBC 5.3 ANSI Driver};SERVER=localmysql;PORT=3306;DATABASE=NOME-DO-BANCO;UID=USUARIO;PWD=SENHA;OPTION=3;"
SET cnnDB = Server.CreateObject("ADODB.Connection")
cnnDB.Open conexao
SET strRS = Server.CreateObject("ADODB.Recordset")
strRS.Open "SELECT DISTINCT * FROM TABELA GROUP BY CAMPO limit 5", cnnDB
DO WHILE NOT strRS.EOF
%>
<strong>categoria:</strong>
<%=strRS("categoria")%>
<br>
<hr/>
<%
strRS.MoveNext
Loop
'fechamos a conexão
cnnDB.Close
Set cnnDB = Nothing
Set strRS = Nothing
%>
</html>