<%
Dim dbconn As SqlConnection
Dim dbCMD As SqlCommand
Dim dtr As SqlDataReader
dbconn = New SqlConnection("Data Source=192.168.103.124;Initial Catalog=KIWI;User ID=sa;Password=P@ssw0rd")
dbconn.Open()
dbCMD = New SqlCommand("SELECT top 5 Type_,Shost,Src,Smac,count(Src) as num FROM EventLogd group by Type_,shost,Src,Smac order by count(Src) Desc", dbconn) ' slow query
dtr = dbCMD.ExecuteReader()
Dim virus As String
While dtr.Read()
virus = dtr(0)
Dim Name As String = dtr(1)
Dim Src As String = dtr(2)
Dim Smac As String = dtr(3)
%>
<tr>
<td><% Response.Write(virus) %></td>
<td><% Response.Write(Name)%></td>
<td><% Response.Write(Src)%></td>
<td><% Response.Write(Smac) %> </td>
<td align ="center"><a href="Ipscan_Table2.aspx"> <i class="fa fa-dashboard fa-fw"></a></td>
</tr>
<% End While
dtr.Close()
dbconn.Close()
%>