<% @Language="VBScript" %> <% Option Explicit %> <% '------------------------------------------------------------- ' Scripts Configuration '------------------------------------------------------------- SetNotCache() 'LoginAuth '------------------------------------------------------------- ' Object Declaration '------------------------------------------------------------- '------------------------------------------------------------- ' Procedure Declaration '------------------------------------------------------------- Sub Dispose() If RecordSet.State = adStateOpen Then RecordSet.Close If Connection.State = adStateOpen Then Connection.Close End Sub '------------------------------------------------------------- ' Request Variables '------------------------------------------------------------- '------------------------------------------------------------- ' Local Variables '------------------------------------------------------------- Dim i '------------------------------------------------------------- ' TableField Variables '------------------------------------------------------------- Dim TOTAL_CNT Dim YESTERDAY_CNT Dim TODAY_CNT '------------------------------------------------------------- ' SQL String '------------------------------------------------------------- Dim strSql '------------------------------------------------------------- ' 처리문 '------------------------------------------------------------- strSql = "SELECT " _ & " A.TOTAL_CNT AS TOTAL_CNT, " _ & " B.YESTERDAY_CNT AS YESTERDAY_CNT, " _ & " C.TODAY_CNT AS TODAY_CNT " _ & "FROM " _ & " (SELECT COUNT(1) AS TOTAL_CNT FROM T_CONNECT) A, " _ & " (SELECT COUNT(1) AS YESTERDAY_CNT FROM T_CONNECT WHERE CON_DATE = '" & Date - 1 & "') B, " _ & " (SELECT COUNT(1) AS TODAY_CNT FROM T_CONNECT WHERE CON_DATE = '" & Date & "') C" Retrieve RecordSet, strSql, Connection TOTAL_CNT = RecordSet("TOTAL_CNT") YESTERDAY_CNT = RecordSet("YESTERDAY_CNT") TODAY_CNT = RecordSet("TODAY_CNT") RecordSet.Close %> DTR홈페이지 방문을 환영합니다.
<% dim sql sql="select top 5 * from T_BRD_DATA " sql=sql & " where B_ID='Cust-New'" sql=sql & " order by WRITE_DATE DESC" rs.open sql,connection do while not rs.eof %> <% rs.MoveNext loop rs.close %>
  - &ldno=<%=rs("D_NO")%>"><%=rs("SUBJECT")%>