28,391
社区成员
发帖
与我相关
我的任务
分享
DBPath_1 = "Provider=sqloledb;" & "Data Source=服务器IP地址;Initial Catalog=数据库名;User Id=数据库访问用户名;Password=访问密码;"
DBPath_2 = "DRIVER=SQL Server;server=数据库服务器名;uid=用户名;pwd=密码;database=数据库名;"
<%
sql "UPDATE BM_ProcurementSystem SET FHSL=SL + '=' + YSCMFB,FHR='" & request.Cookies("loginname") & "', FHSJ = Now() WHERE (FHSL='' or FHSL is null) and (FHSJ='' or FHSJ is null) and (YSCMFB <>'' or YSCMFB is not null) and FLAG <>1 and (RQ between '"&starttime&"' and '"&endtime&"')"
conn.Execute sql
conn.Close
response.write " <script>alert('批量发货成功!');location.href('inboundSQL.asp"&request.Cookies("inboundSQLURLOption")&"'); </script>"
%>
<%
Set PLFHRS = server.CreateObject("ADODB.recordset")
PLFHRS.CursorLocation = 3
PLFHRS.open "select FHSL,FHR,FHSJ,SL,YSCMFB from BM_ProcurementSystem where (FHSL='' or FHSL is null) and (FHSJ='' or FHSJ is null) and (YSCMFB <>'' or YSCMFB is not null) and FLAG <>1 and (RQ between '"&starttime&"' and '"&endtime&"')",conn,1,4
Do While Not PLFHRS.EOF
PLFHRS("FHSL") = Trim(PLFHRS("SL")) & "=" & Trim(PLFHRS("YSCMFB"))
PLFHRS("FHSJ") = Now()
PLFHRS("FHR") = request.Cookies("loginname")
PLFHRS.MoveNext
Loop
PLFHRS.UpdateBatch
PLFHRS.Close
Set PLFHRS=Nothing
conn.Close
response.write " <script>alert('批量发货成功!');location.href('inboundSQL.asp"&request.Cookies("inboundSQLURLOption")&"'); </script>"
%>