To declare a variable in VBSCRIPT use
Dim
example:
Dim SQLWeight
a group define:
Dim sDB2String,UID, SQLStmt, Connection
as always the connection string
Then you can use this variable to retrieve Iseries data
into this variable.
Dim
example:
Dim SQLWeight
a group define:
Dim sDB2String,UID, SQLStmt, Connection
as always the connection string
Code:
Set Connection = Server.CreateObject("ADODB.Connection") Connection.Open "Provider=IBMDA400;User ID=NAME;Password=PASSWORD;Data Source=10.10.10.10;"
into this variable.
Code:
Dim SQLweight <% sqlstmt = "SELECT sum(WADLWT)as TotalShippedLBI FROM lbifil.wkartno WHERE WADAT = " & currentdate set SQLweight = connection.Execute(sqlstmt) %> <% Response.Write " <B>Routed Today (LBI):</b> " & SQLweight("totalshippedLBI")%> <BR> <% sqlstmt = "SELECT sum(WADLWT)as TotalShippedLSN FROM lsnfil.wkartno WHERE WADAT = " & currentdate set SQLweight = connection.Execute(sqlstmt) %> <% Response.Write " <B>Routed Today (LSN):</b> " & SQLweight("totalshippedLSN")%> <BR> <% sqlstmt = "SELECT sum(WADLWT)as TotalShippedPDM FROM pdmfil.wkartno WHERE WADAT = " & currentdate set SQLweight = connection.Execute(sqlstmt) %> <% Response.Write " <B>Routed Today (PDM):</b> " & SQLweight("totalshippedPDM")%> <BR>
Comment