Set drs = New ADODB.Recordset
drs.CursorLocation = adUseClient
drs.Open "Select ID,COUNT(ID) AS total from (" _
& G1 & " union " & G2 & " union " & G3 & " union " & G4 _
& " union " & G5 & " union " & G6 & " union " & G7 _
& ") Group By ID", dcn, adOpenStatic, adLockPessimistic
當我把G1~G7的資料表JOIN起來之後,我發現G1和G7的資料不在Drs裡面,這要如何解決呢?謝謝
drs.CursorLocation = adUseClient
drs.Open "Select ID,COUNT(ID) AS total from (" _
& G1 & " union " & G2 & " union " & G3 & " union " & G4 _
& " union " & G5 & " union " & G6 & " union " & G7 _
& ") Group By ID", dcn, adOpenStatic, adLockPessimistic
當我把G1~G7的資料表JOIN起來之後,我發現G1和G7的資料不在Drs裡面,這要如何解決呢?謝謝
全站熱搜
留言列表