Rev 125 | Blame | Compare with Previous | Last modification | View Log | RSS feed
<%@LANGUAGE="VBSCRIPT"%><%'====================================================='| |'| RequestPackageVersionHistoryMetrics.asp |'| |'=====================================================%><%Option explicit' Good idea to set when using redirectResponse.Expires = 0 ' always load the page, dont store%><!--#include file="common/conf.asp"--><!--#include file="common/globals.asp"--><!--#include file="common/formating.asp"--><!--#include file="common/qstr.asp"--><!--#include file="common/common_subs.asp"--><%'------------ Variable Definition -------------Dim rsTempDim rsMetricsDim parPvId'------------ Constants Declaration -----------'------------ Variable Init -------------------parPvId = Request("pv_id")'----------------------------------------------%><%'------------------------------------------------------------------------------------------------------------------------' Thus function formulates a query that is intended to find the top 10 packages that have changed the most in a period of' time, limited in scope to those packages that have at least one version in the specified release.' The function relies upon the user of this ASP file having setup the Interval parameter as needed (see RequestReleasePackages.asp)Function formQueryString2Dim qsqs = " SELECT pv_id, last_pv_id, pkg_id, pkg_version, v_ext, created_stamp, modified_stamp FROM package_versions " _& " CONNECT BY NOCYCLE PRIOR last_pv_id = pv_id " _& " START WITH pv_id = :PV_ID " _& " ORDER BY pv_id DESC "formQueryString2 = qsEnd Function'------------------------------------------------------------------------------------------------------------------------%><%'------------------------ MAIN LINE ---------------------------------'--------------------------------------------------------------------%><table width="100%" border="0" cellspacing="1" cellpadding="1"><tr><td background="images/bg_form_lightbluedark.gif"><table width="100%" border="0" cellspacing="1" cellpadding="1"><tr><td nowrap class="body_txt" valign="top" background="images/bg_form_lightbluedark.gif">Package Version  </td><td nowrap class="body_txt" valign="top" background="images/bg_form_lightbluedark.gif">Autobuilt  </td><td nowrap class="body_txt" valign="top" background="images/bg_form_lightbluedark.gif">Lines Of Code  </td><td nowrap class="body_txt" valign="top" background="images/bg_form_lightbluedark.gif">Unit Tested  </td><td nowrap class="body_txt" valign="top" background="images/bg_form_lightbluedark.gif">Autotested  </td><td nowrap class="body_txt" valign="top" background="images/bg_form_lightbluedark.gif">Branches  </td><td nowrap class="body_txt" valign="top" background="images/bg_form_lightbluedark.gif">Last Modified  </td></tr><%' Get the list of ancestor versionsOraDatabase.Parameters.Add "PV_ID", Request("pv_id"), ORAPARM_INPUT, ORATYPE_NUMBERSet rsTemp = OraDatabase.DbCreateDynaset( formQueryString2, cint(0))OraDatabase.Parameters.Remove "PV_ID"If rsTemp.RecordCount < 1 Then%><tr><td colspan="7" background="images/bg_form_lightgray.gif" nowrap> </td></tr><%ElseWhile ((NOT rsTemp.BOF) AND (NOT rsTemp.EOF))OraDatabase.Parameters.Add "PV_ID", rsTemp("pv_id"), ORAPARM_INPUT, ORATYPE_NUMBERSet rsMetrics = OraDatabase.DbCreateDynaset( GetQuery("PackageVersionMetrics.sql"), cint(0))OraDatabase.Parameters.Remove "PV_ID"If rsMetrics.RecordCount > 0 Then%><tr><td nowrap class="body_txt" background="images/bg_form_lightgray.gif"><a class="txt_linked" href="dependencies.asp?pv_id=<%=rsTemp("pv_id")%>"><%=rsMetrics("pkg_name")%><%=VBNEWLine%><%=rsMetrics("pkg_version")%></a>   </td><td nowrap class="body_txt" background="images/bg_form_lightgray.gif"><%If rsMetrics("is_autobuildable") = "Y" Then%>Yes<%Else%>No<%End If%></td><td nowrap class="body_txt" background="images/bg_form_lightgray.gif"><%=rsMetrics("code_lines")%></td><td nowrap class="body_txt" background="images/bg_form_lightgray.gif"><%If rsMetrics("unit_tested") = "Y" Then%>Yes<%Else%>No<%End If%></td><td nowrap class="body_txt" background="images/bg_form_lightgray.gif"><%If rsMetrics("autotested") = "Y" Then%>Yes<%Else%>No<%End If%></td><td nowrap class="body_txt" background="images/bg_form_lightgray.gif"><%=rsMetrics("branches")%></td><td nowrap class="body_txt" background="images/bg_form_lightgray.gif"><%=EuroDate(rsTemp("modified_stamp"))%></td></tr><%End IfrsTemp.MoveNextrsMetrics.CloseWEndrsTemp.CloseSet rsTemp = nothingEnd If%></table></td></tr></table><br><%Call Destroy_All_Objects%>