- Northwind DB에 대항하여 수업시간에 예기한 방식의 "읽기4"를 브라우저에서 실행후 스크린 켑쳐를 한다.
read6.asp 파일 5월 11일
<html>
<body>
<%
Set Conn = Server.CreateObject("ADODB.Connection")
Conn.ConnectionString = "DSN=win.dsn"
Conn.Open
Set Rs = Server.CreateObject("ADODB.Recordset")
Rs.Open "Select CategoryID, CategoryName, Description From tblCategories Where CategoryID='2';", Conn
Response.Write(Rs("CategoryID"))
Response.Write(Rs("CategoryName"))
Response.Write(Rs("Description"))
Rs.close
set Rs=nothing
Conn.close
Set Conn=nothing
%>
</body>
</html>
실행값
2CondimentsSweet and savory sauces, relishes, spreads, and seasonings
2번째 줄을 출력