%@ LANGUAGE="VBScript" %>
<%
Set Connection = Server.CreateObject("ADODB.Connection")
Connection.Mode = adModeRead
Connection.Open phdb_rd_repl
SQLStmtx = "select to_char(sysdate,'MM/DD/YYYY') ddate,to_char(sysdate,'HH24:MI:SS') ttime,global_name from global_name "
' response.write(SQLStmtx & "
" )
Set RSx = Connection.Execute(SQLStmtx)
If Not RSx.EOF Then
select case CStr(RSx("global_name"))
case "PHDB.WORLD"
dbname="Main Phobos Database"
case "ORACLE.WORLD"
dbname="Phobos Server (old) Database"
case "KRPHOBOS.WORLD"
dbname="Krakow Database"
case "ROCHESTER.WORLD"
dbname="Rochester Database"
end select
Else
dbname="Undefined Database"
End If
'
' Check the consistency of the dates for the latest map
'
SQLStmtC= " select "
SQLStmtC= SQLStmtC & " to_char(max(last_config),'MM/DD/YYYY HH24:MI:SS') lcfg_p,to_char(max(last_config),'YYYYMMDDHH24MISS') lcfg_c, "
SQLStmtC= SQLStmtC & " to_char(max(last_connect),'MM/DD/YYYY HH24:MI:SS') lcon_p,to_char(max(last_connect),'YYYYMMDDHH24MISS') lcon_c, "
SQLStmtC= SQLStmtC & " to_char(max(last_map),'MM/DD/YYYY HH24:MI:SS') lmap_p,to_char(max(last_map),'YYYYMMDDHH24MISS') lmap_c "
SQLStmtC= SQLStmtC & " from "
SQLStmtC= SQLStmtC & " (select max(startdate) last_config from assembly.fec_config where startdate<=sysdate), "
SQLStmtC= SQLStmtC & " (select max(startdate) last_connect from assembly.fec_connect where startdate<=sysdate),"
SQLStmtC= SQLStmtC & " (select max(reqdate) last_map from assembly.fec_map_log where reqdate<=sysdate) "
Set RSC = Connection.Execute(SQLStmtC)
lcfg_c=CDBl(RSC("lcfg_c"))
lcon_c=CDBL(RSC("lcon_c"))
lmap_c=CDBL(RSC("lmap_c"))
If lcfg_c>lmap_c Or lcon_c>lmap_c Then
ivalid=0
If lcfg_c>lmap_c And lcon_c<=lmap_c Then
mess="Latest map with validity time of " & CStr(RSC("lmap_p")) & " may not be up to date, FEC configuration has been changed on " & CStr(RSC("lcfg_p"))
Elseif lcfg_c<=lmap_c And lcon_c>lmap_c Then
mess="Latest map with validity time of " & CStr(RSC("lmap_p")) & " may not be up to date, Cables have been connected or disconnected on " & CStr(RSC("lcon_p"))
Else
mess="Latest map with validity time of " & CStr(RSC("lmap_p")) & " may not be up to date, FEC and cable configurations have been changed on " & CStr(RSC("lcfg_p")) & " and " & CStr(RSC("lcon_p")) & " respectively."
End if
Else
ivalid=1
mess="Latest map with validity time of " & CStr(RSC("lmap_p")) & " is up to date"
End If
' response.write(SQLStmtC & "
" & vbCrLf)
SQLStmt = "select to_char(fml.REQDATE,'MM/DD/YYYY HH24:MI:SS') reqdate,to_char(fml.CRDATE ,'MM/DD/YYYY HH24:MI:SS') crdate, "
SQLStmt = SQLStmt & " to_char(fml.REQDATE ,'YYYYMMDDHH24MISS') ndate,fml.operator,fml.comments, "
SQLStmt = SQLStmt & " nvl(dbms_lob.getlength(fmb.mapdata),-1024)/1024 mbytes "
SQLStmt = SQLStmt & " from ASSEMBLY.FEC_MAP_LOG fml,assembly.fec_map_blob fmb "
SQLStmt = SQLStmt & " where fml.reqdate=fmb.reqdate(+) "
SQLStmt = SQLStmt & " ORDER BY fml.reqdate desc "
' response.write(SQLStmt & "
" & vbCrLf)
Set RS = Connection.Execute(SQLStmt)
%>
Status on <%=RSx("ddate")%> at <%=RSx("ttime")%> in <%=dbname%>
<% If ivalid=1 Then fcolor="#008000" else fcolor="#FF0000" End If %><%=mess%>
BLOB | Active Strings | Channel Calculator | Create Text File | Create Short Text File | Validity Date | Creation Date | Created by | Comments |
"
onClick="openWindow(this,'Activestrings',1000,800,'yes',0,0)" >![]() |
"
onClick="openWindow(this,'Maps',250,200,'no')">![]() |
">![]() |
">![]() |
<%=RS("REQDATE")%> | <%=RS("CRDATE")%> | <%=RS("Operator")%> | <%=RS("Comments")%> |