回覆列表
  • 1 # 使用者9760286159281

    你是要查詢資料庫中某個欄位下的相同資料吧,我給你寫2個例子(資料庫執行效率高)select * from dbo.MediafileInfo as a where(VideoDownUrl IN (SELECT VideoDownUrl FROM MediafileInfo AS B WHERE A.ProgramID B.ProgramID))(資料庫執行效率低)SELECT *FROM MediafileInfo AS AWHERE (SELECT COUNT(*) FROM MediafileInfo WHERE VideoDownUrl=A.VideoDownUrl)>1

  • 2 # 李益全

    deletefromabcwhere(id,a,b)in(select*from(selectmin(id),a,bfromabcgroupbyid)astmp);

    -----------------------------------------------

    欄位用ab代替了,看的明白吧?

  • 中秋節和大豐收的關聯?
  • 電腦無聲了,怎麼決?和軟體有關係嗎?