Re: [問題] ASP一次刪除多筆資料

看板Web_Design作者 (骨頭)時間18年前 (2007/04/13 18:03), 編輯推噓0(001)
留言1則, 1人參與, 最新討論串3/3 (看更多)
※ 引述《dreamers210 (不要再叫我5樓了~~~)》之銘言: : ※ 引述《sudada (淑打綠)》之銘言: : DELID = SPLIT( REQUEST("DEL"), ", " ) : FOR I = 0 TO UBOUND(DELID) : IF I > 0 AND I =< UBOUND(DELID) THEN : DELOPTIONS = DELOPTIONS & " OR [id]=" : END IF : DELOPTIONS = DELOPTIONS & DELID(I) : NEXT : CONN.EXECUTE "Delete From album Where [id]=" & DELOPTIONS : 這樣就可以了 DELID = SPLIT( REQUEST("DEL"), ", " ) FOR I = 0 TO UBOUND(DELID) DELOPTIONS = DELOPTIONS & " OR [id]=" NEXT CONN.EXECUTE "Delete From album Where 1=0 " & DELOPTIONS -- 這是偷懶的作法 XD -- I am a person, and I am always thinking . Thinking in love , Thinking in life , Thinking in why , Thinking in worth. I can't believe any of what , I am just thinking then thinking , but worst of all , most of mine is thinking not actioning... -- ※ 發信站: 批踢踢實業坊(ptt.cc) ◆ From: 220.134.27.68

04/13 18:03, , 1F
1=0 => false 可別寫成 1=1 會很慘的 XD
04/13 18:03, 1F
文章代碼(AID): #167rLPdK (Web_Design)
文章代碼(AID): #167rLPdK (Web_Design)