最新国产好看的视频,伊人天堂AV在线,国产Aaaaaa视频,蜜臀视频在线观看一区,人妻av色图,密臀久久久精品影片,青青视频免费观看毛片,久草在线观看视,国产三级精品色情在线

ASP批量更新代碼

 更新時(shí)間:2008年03月08日 23:38:42   作者:  
我作了一個(gè)ASP靜態(tài)站,由于網(wǎng)站改片,所以所有靜態(tài)頁都要更新,原來是以時(shí)間命名為文件命,現(xiàn)在全部改成ID命名,但數(shù)據(jù)庫內(nèi)的保存地址的那個(gè)字段無法更新,請(qǐng)各位大蝦指點(diǎn)一二,小弟不勝感激...................
<!--#include file="../Conn.asp"-->
<%
set rs=server.createobject("adodb.recordset")
sql="select * from article where bigtypes='我愛你'order by id desc"   找出數(shù)據(jù)庫內(nèi)類別為我愛你的所有數(shù)據(jù)
rs.open sql,conn,1,3
if not rs.eof then
do while not rs.eof
fname = rs("id")&".html"
folder = "../html/Info/"
c_filepath = folder&fname

rs("filepath")=c_filepath
rs.update

rs.movenext
loop
end if
response.redirect "成功....."
%>
解決方法:
復(fù)制代碼 代碼如下:

<%
set rs=server.createobject("adodb.recordset")
sql="select * from article where bigtypes='我愛你'order by id desc"   找出數(shù)據(jù)庫內(nèi)類別為我愛你的所有數(shù)據(jù)
rs.open sql,conn,1,3
if not rs.eof then
do while not rs.eof
fname = rs("id")&".html"
folder = "../html/Info/"
c_filepath = folder&fname

conn.execute("update article set filepath='"&c_filepath&"' where id="&rs("id"))

rs.movenext
loop
end if
response.redirect "成功....."
%>

相關(guān)文章

最新評(píng)論

郸城县| 镇雄县| 平舆县| 阳原县| 孙吴县| 逊克县| 永寿县| 鹤岗市| 旬邑县| 绥滨县| 灵川县| 宽甸| 慈溪市| 桐柏县| 恩平市| 会宁县| 金溪县| 龙南县| 晋江市| 绥棱县| 二连浩特市| 历史| 永靖县| 长海县| 侯马市| 通州区| 米林县| 龙陵县| 团风县| 宜城市| 沂源县| 津南区| 玉林市| 靖江市| 贡山| 沙湾县| 镇平县| 伊通| 沂南县| 大兴区| 汝阳县|