<% ' Count only PCs (pctypeid IS NOT NULL) for MA3 stats strSQL2 = "SELECT COALESCE(sum(case when appid = '42' then 1 else 0 end), 0) AS ma3count," &_ "(SELECT COUNT(*) FROM machines WHERE machines.isactive=1 AND machines.pctypeid IS NOT NULL) AS machinecount "& _ "FROM installedapps WHERE appid=42 and installedapps.isactive=1" set rs2 = objconn.Execute(strSQL2) ma3count = rs2("ma3count") machinecount = rs2("machinecount") If IsNull(ma3count) Or ma3count = "" Then ma3count = 0 If IsNull(machinecount) Or machinecount = "" Or CInt(machinecount) = 0 Then machinecount = 1 ma2count = CInt(machinecount) - CInt(ma3count) ma3pct = FormatNumber(CInt(ma3count)/Cint(machinecount)*100,2) ma2pct = FormatNumber(CInt(ma2count)/Cint(machinecount)*100,2) %>
Machine Auth 3.1
Machine Auth 3.0 <%Response.Write(ma3count)%> <%Response.Write(ma3pct)%>%
Machine Auth 2.0 <%Response.Write(ma2count)%> <%Response.Write(ma2pct)%>%