Subversion Repositories DevTools

Rev

Rev 6592 | Rev 6615 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 6592 Rev 6613
Line 16... Line 16...
16
<!--#include file="common/formating.asp"-->
16
<!--#include file="common/formating.asp"-->
17
<!--#include file="common/qstr.asp"-->
17
<!--#include file="common/qstr.asp"-->
18
<!--#include file="common/common_subs.asp"-->
18
<!--#include file="common/common_subs.asp"-->
19
<%
19
<%
20
'------------ Variable Definition -------------
20
'------------ Variable Definition -------------
21
Dim rsTemp
-
 
22
Dim rsMetrics
21
Dim rsMetrics
23
Dim parPvId
22
Dim parPvId
24
'------------ Constants Declaration -----------
23
'------------ Constants Declaration -----------
25
'------------ Variable Init -------------------
24
'------------ Variable Init -------------------
26
parPvId = Request("pv_id")
25
parPvId = Request("pv_id")
27
'----------------------------------------------
26
'----------------------------------------------
28
%>
27
%>
29
<%
28
<%
30
'------------------------------------------------------------------------------------------------------------------------
-
 
31
' Thus function formulates a query that is intended to find the top 10 packages that have changed the most in a period of
-
 
32
' time, limited in scope to those packages that have at least one version in the specified release.
-
 
33
' The function relies upon the user of this ASP file having setup the Interval parameter as needed (see RequestReleasePackages.asp)
-
 
34
Function formQueryString2
-
 
35
 
-
 
36
   Dim qs
-
 
37
 
-
 
38
   qs  = " SELECT pv_id, last_pv_id, pkg_id, pkg_version, v_ext, created_stamp, TO_CHAR( modified_stamp,'DD-Mon-YYYY HH24:MI:SS' ) AS modified_stamp FROM package_versions " _
-
 
39
       & " CONNECT BY NOCYCLE PRIOR last_pv_id = pv_id            " _
-
 
40
       & " START WITH pv_id = :PV_ID                              " _
-
 
41
       & " ORDER BY pv_id DESC                                    "
-
 
42
 
-
 
43
   formQueryString2 = qs
-
 
44
End Function
-
 
45
 
-
 
46
 
-
 
47
 
-
 
48
'------------------------------------------------------------------------------------------------------------------------
-
 
49
%>
-
 
50
<%
-
 
51
'------------------------ MAIN LINE ---------------------------------
29
'------------------------ MAIN LINE ---------------------------------
52
'--------------------------------------------------------------------
30
'--------------------------------------------------------------------
53
%>
31
%>
-
 
32
<!-- RequestPackageVersionHistoryMetrics.asp -->
54
<table width="100%" border="0" cellspacing="1" cellpadding="1">
33
<table width="100%" border="0" cellspacing="1" cellpadding="1">
-
 
34
<tr>
55
   <tr>
35
  <td>
56
      <td background="images/bg_form_lightbluedark.gif">
-
 
57
         <table width="100%" border="0" cellspacing="1" cellpadding="1">
36
     <table width="100%" border="0" cellspacing="1" cellpadding="1">
58
            <tr>
37
        <tr class="form_field_bg">
59
               <td nowrap class="body_txt" valign="top" background="images/bg_form_lightbluedark.gif">Package Version&nbsp&nbsp</td>
38
           <td nowrap class="body_row" valign="top" >Package Version</td>
60
               <td nowrap class="body_txt" valign="top" background="images/bg_form_lightbluedark.gif">Autobuilt&nbsp&nbsp</td>
39
           <td nowrap class="body_row" valign="top" >Autobuilt</td>
-
 
40
           <td nowrap class="body_row" valign="top" >Build Reason</td>
61
               <td nowrap class="body_txt" valign="top" background="images/bg_form_lightbluedark.gif">Lines Of Code&nbsp&nbsp</td>
41
           <td nowrap class="body_row" valign="top" >Lines Of Code</td>
62
               <td nowrap class="body_txt" valign="top" background="images/bg_form_lightbluedark.gif">Unit Tested&nbsp&nbsp</td>
42
           <td nowrap class="body_row" valign="top" >Unit Tested</td>
63
               <td nowrap class="body_txt" valign="top" background="images/bg_form_lightbluedark.gif">Autotested&nbsp&nbsp</td>
43
           <td nowrap class="body_row" valign="top" >Autotested</td>
64
               <td nowrap class="body_txt" valign="top" background="images/bg_form_lightbluedark.gif">Last Modified&nbsp&nbsp</td>
44
           <td nowrap class="body_row" valign="top" >Last Modified</td>
65
            </tr>
45
        </tr>
66
 
46
 
67
            <%
47
        <%
68
            ' Get the list of ancestor versions
48
        ' Get the list of ancestor versions
69
            OraDatabase.Parameters.Add "PV_ID", Request("pv_id"),    ORAPARM_INPUT, ORATYPE_NUMBER
49
        OraDatabase.Parameters.Add "PV_ID", Request("pv_id"),    ORAPARM_INPUT, ORATYPE_NUMBER
70
 
-
 
71
            Set rsTemp = OraDatabase.DbCreateDynaset( formQueryString2, cint(0))
50
        Set rsMetrics = OraDatabase.DbCreateDynaset( GetQuery("PackageVersionMetrics.sql"), cint(0))
72
 
-
 
73
            OraDatabase.Parameters.Remove "PV_ID"
51
        OraDatabase.Parameters.Remove "PV_ID"
74
 
52
 
75
            If rsTemp.RecordCount < 1 Then
53
        If rsMetrics.RecordCount < 1 Then
76
            %>
54
        %>
77
               <tr>
55
           <tr class="form_field_grey_bg">
78
                  <td colspan="7" background="images/bg_form_lightgray.gif" nowrap>&nbsp;</td>
56
              <td colspan="7" class="body_row" nowrap>Non Found</td>
79
               </tr>
57
           </tr>
80
            <%
58
        <%
81
            Else
59
        Else
82
 
-
 
83
               While ((NOT rsTemp.BOF) AND (NOT rsTemp.EOF))
60
           While ((NOT rsMetrics.BOF) AND (NOT rsMetrics.EOF))
84
 
-
 
85
                  OraDatabase.Parameters.Add "PV_ID", rsTemp("pv_id"),    ORAPARM_INPUT, ORATYPE_NUMBER
-
 
86
 
-
 
87
                  Set rsMetrics = OraDatabase.DbCreateDynaset( GetQuery("PackageVersionMetrics.sql"), cint(0))
-
 
88
 
-
 
89
                  OraDatabase.Parameters.Remove "PV_ID"
-
 
90
                  If rsMetrics.RecordCount > 0 Then
-
 
91
                  %>
61
              %>
92
                     <tr>
62
                 <tr class="form_field_grey_bg">
93
                        <td nowrap class="body_txt" background="images/bg_form_lightgray.gif">
63
                    <td nowrap class="body_row">
94
                           <a class="txt_linked" href="dependencies.asp?pv_id=<%=rsTemp("pv_id")%>">
64
                       <a class="txt_linked" href="dependencies.asp?pv_id=<%=rsMetrics("pv_id")%>"><%=rsMetrics("pkg_name")%>&nbsp;<%=rsMetrics("pkg_version")%></a>
95
                              <%=rsMetrics("pkg_name")%>
-
 
96
                              <%=VBNEWLine%><%=rsMetrics("pkg_version")%>
-
 
97
                           </a>
-
 
98
                           &nbsp&nbsp&nbsp
-
 
99
                        </td>
65
                    </td>
100
                        <td nowrap class="body_txt" background="images/bg_form_lightgray.gif">
-
 
101
                           <%If rsMetrics("is_autobuildable") = "Y" Then%>Yes<%Else%>No<%End If%>
66
                    <td nowrap class="body_row"><%=IIf(rsMetrics("is_autobuildable") = "Y", "Yes", "No")%></td>
102
                        </td>
-
 
103
                        <td nowrap class="body_txt" background="images/bg_form_lightgray.gif"><%=rsMetrics("code_lines")%></td>
67
                    <td nowrap class="body_row"><%=rsMetrics("reason")%></td>
104
                        <td nowrap class="body_txt" background="images/bg_form_lightgray.gif">
68
                    <td nowrap class="body_row"><%=rsMetrics("code_lines")%></td>
105
                           <%If rsMetrics("unit_tested") = "Y" Then%>Yes<%Else%>No<%End If%>
69
                    <td nowrap class="body_row"><%=IIf(rsMetrics("unit_tested") = "Y", "Yes", "No")%></td>
106
                        </td>
-
 
107
                        <td nowrap class="body_txt" background="images/bg_form_lightgray.gif">
-
 
108
                            <%If IsNull(rsMetrics("autotested")) OR rsMetrics("autotested") <> "Y" Then %>No<%ElseIf rsMetrics("test_count") = "0" Then%>?<%Else%><%=rsMetrics("test_count")%><%End If%>
70
                    <td nowrap class="body_row"><%If IsNull(rsMetrics("autotested")) OR rsMetrics("autotested") <> "Y" Then %>No<%ElseIf rsMetrics("test_count") = "0" Then%>?<%Else%><%=rsMetrics("test_count")%><%End If%></td>
109
                        </td>
-
 
110
                        <td nowrap class="body_txt" background="images/bg_form_lightgray.gif"><%=rsTemp("modified_stamp")%></td>
71
                    <td nowrap class="body_row"><%=rsMetrics("modified_stamp")%></td>
111
                     </tr>
72
                 </tr>
112
                  <%
73
              <%
113
                  End If
-
 
114
                  rsTemp.MoveNext
74
           rsMetrics.MoveNext
115
                  rsMetrics.Close
75
           WEnd
116
               WEnd
76
        End If
117
               rsTemp.Close
77
        rsMetrics.Close
118
               Set rsTemp = nothing
78
        Set rsMetrics = nothing
119
 
-
 
120
            End If
-
 
121
            %>
79
        %>
122
         </table>
80
     </table>
123
      </td>
81
  </td>
124
   </tr>
82
</tr>
125
</table>
83
</table>
126
<br>
84
<br>
127
 
-
 
128
<%
85
<%
129
Call Destroy_All_Objects
86
Call Destroy_All_Objects
130
%>
87
%>