...and an example straight from W3C schools ADO section
<html>
<body>
<%
set conn=Server.CreateObject("ADODB.Connection")
conn.Provider="Microsoft.Jet.OLEDB.4.0"
conn.Open "c:/webdata/northwind.mdb"
sql="INSERT INTO customers (customerID,companyname,"
sql=sql & "contactname,address,city,postalcode,country)"
sql=sql & " VALUES "
sql=sql & "('" & Request.Form("custid") & "',"
sql=sql & "'" & Request.Form("compname") & "',"
sql=sql & "'" & Request.Form("contname") & "',"
sql=sql & "'" & Request.Form("address") & "',"
sql=sql & "'" & Request.Form("city") & "',"
sql=sql & "'" & Request.Form("postcode") & "',"
sql=sql & "'" & Request.Form("country") & "')"
on error resume next
conn.Execute sql,recaffected
if err<>0 then
Response.Write("No update permissions!")
else
Response.Write("<h3>" & recaffected & " record added</h3>")
end if
conn.close
%>
</body>
</html>
As well as some ripped from a functional database interface from work (non-proprietary)
var adoConn = new ActiveXObject("ADODB.Connection");
var adoRS = new ActiveXObject("ADODB.Recordset");
adoConn.Open(adoConnectString);
adoRS.Open(QString, adoConn, 1, 3);
var adoQstringEOF = adoRS.EOF
if (adoQstringEOF == false)
{
userNameFromDatabase.value = adoRS.Fields("Username").value;
passwordFromDatabase.value = adoRS.Fields("Password").value;
adoRS.Update;
adoRS.Close();
adoConn.Close();
}
else if (adoQstringEOF == true)
{
adoRS.Close();
adoConn.Close();
alert ("Username not found")
}
}