1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60
| <%Response.Buffer = "False"
Response.ContentType = "application/vnd.ms-excel"%>
<html>
<head>
<title>Ageing spécifique code vendor</title>
</head>
<body>
<table border='1' cellpadding='0' cellspacing='0'>
<tr>
<th>BranchNbr</th>
<th>AverageCostLocAmt</th>
<th>AVGValueBOH</th>
<th>AgingMonthDescription</th>
[...]
<th>AgingDaysRsvLocAmt</th>
<th>AgingDaysRsvPerc</th>
<th>AgingDaysDescription</th>
<th>Currency</th>
<th>LastSalesDt</th>
<th>ProtectedVendor</th>
<th>BaseCostForAmt</th>
<th>PriceSchemeCode</th>
</tr>
<%
'Déclaration de la variable de connexion
Dim cnx
Dim rs
Set cnx = server.createobject("ADODB.Connection")
'Ouverture de la base de données
cnx.open "PROVIDER=SQLOLEDB;DATA SOURCE=FRLS0ITRIM01;UID=RIM_read;PWD=read;DATABASE=RIM_F"
'recordset
Set rs=server.createObject("ADODB.Recordset")
SQL="SELECT BranchNbr, BuyerCode, BuyerName, CodedRsvLocAmt, [...]AgingMonthRsvPerc, AgingMonthRsvLocAmt, boh AS Stock, [Commit], OnOrder, AverageCostLocAmt, ReplacementCostLocAmt FROM V_AnalystagingRealReceiptLocal WHERE ((VendorNbr = '" & Request.QueryString("cdvdor") & "'));"
rs.open SQL,cnx,3,3
do while not rs.eof
response.write "<tr>"
for i=0 to rs.fields.count-1
response.write "<td>" & rs.fields(i).value & "</td>"
next
response.write "</tr>"
rs.movenext
loop
rs.close
set rs=nothing
cnx.close
set cnx=nothing
%>
</table>
</body>
</html> |
Partager