Here is my code
I get error 3075 in my strSQL statement (syntax error (missing operator) in query expression...). Any Ideas?
Here is my SQL statement from my immediate window:
Thanks
Code:
Dim intMasterProjectID, intContractorListID As Integer
Dim strSQL, strContractor As String
Dim dbs As Database
Dim rs As dao.Recordset
intMasterProjectID = Forms![Bid - Master Form]![Master Project ID]
strContractor = Forms![Bid - Master Form]![Bid - Bid Follow Up]![FollowupContractor]
strSQL = "SELECT * FROM [Bid - Contractor List]" & _
"WHERE [Bid - Contractor List].[Contractor] = " & strContractor & _
" AND [Bid - Contractor List].[Master Project ID] = " & intMasterProjectID
Debug.Print "Project ID: " & intMasterProjectID
Debug.Print "Contractor: " & strContractor
Debug.Print "SQL: " & strSQL
Set dbs = CurrentDb
Set rs = dbs.OpenRecordset(strSQL)
I get error 3075 in my strSQL statement (syntax error (missing operator) in query expression...). Any Ideas?
Here is my SQL statement from my immediate window:
Code:
SQL: SELECT * FROM [Bid - Contractor List]WHERE [Bid - Contractor List].[Contractor] = Bud Bailey Construction AND [Bid - Contractor List].[Master Project ID] = -8585313
Thanks