<%
Dim Conn,strSQL,objExec,RepairID
Set Conn = Server.Createobject("ADODB.Connection")
Conn.Open "Driver={SQL Server};Server=localhost;Database=Service;UID=sa;PWD=p@ssw0rd;"
strSQL = ""
strSQL = strSQL &" SELECT TOP 1 RepairID FROM Repair ORDER BY RepairID DESC "
Set objExec = Conn.Execute(strSQL)
Conn.Close()
Set objExec = Nothing
Set Conn = Nothing
%>
<%
Dim Conn,strSQL,objExec,RepairID
Set Conn = Server.Createobject("ADODB.Connection")
Set objExec = Server.CreateObject("ADODB.Recordset")
Conn.Open "Driver={SQL Server};Server=localhost;Database=Service;UID=sa;PWD=p@ssw0rd;"
strSQL = " SELECT TOP 1 RepairID FROM Repair ORDER BY RepairID DESC "
objExec.Open strSQL,Conn
%>