G
Guest
Can anyone tell me why the following SQL code is only giving me 1 record?
There are supposed to be 2 records when I use MsAccess' QBE.
'assy is predefined
Dim db As Database
Set db = CurrentDb
Dim s As String
Dim rs As DAO.Recordset
s = " SELECT dbo_BOM.Component, dbo_PartMaster.DescText"
s = s & " FROM dbo_BOM RIGHT JOIN dbo_PartMaster ON dbo_BOM.Component =
dbo_PartMaster.PartNumber"
s = s & " WHERE ((dbo_BOM.Assembly)= '" & assy & "');"
Set rs = db.OpenRecordset(s, DB_OPEN_DYNASET)
MsgBox "rs.recordcount = " & rs.RecordCount
Why is rs.recordcount only giving me 1 record? Please help. thanks in
advance.
There are supposed to be 2 records when I use MsAccess' QBE.
'assy is predefined
Dim db As Database
Set db = CurrentDb
Dim s As String
Dim rs As DAO.Recordset
s = " SELECT dbo_BOM.Component, dbo_PartMaster.DescText"
s = s & " FROM dbo_BOM RIGHT JOIN dbo_PartMaster ON dbo_BOM.Component =
dbo_PartMaster.PartNumber"
s = s & " WHERE ((dbo_BOM.Assembly)= '" & assy & "');"
Set rs = db.OpenRecordset(s, DB_OPEN_DYNASET)
MsgBox "rs.recordcount = " & rs.RecordCount
Why is rs.recordcount only giving me 1 record? Please help. thanks in
advance.