Error on Execute Update statement

bartw72

Registered User.
Local time
Today, 09:20
Joined
May 12, 2005
Messages
14
I am getting the error "Too Few Parameters. Expected 1." when running the following Execute:

' Add Offer Numbers to tblWIP
Set dbOfferNumberAdd = CurrentDb
dbOfferNumberAdd.Execute ("UPDATE qryWIP SET [OfferNumber] = '" & strOfferNumberAdd & "' WHERE [OfferDescription] = '" & strOffer & "'"), dbFailOnError
dbOfferNumberAdd.Close
Set dbOfferNumberAdd = Nothing

I would appreciate any advise if my syntax is wrong. I have a value in both of my strings and the query I am updating has a blank value in the OfferNumber field where the OfferDescription matches the strOfferDescription value.
 
If the [OfferNumber] field is numeric then you will want to leave off the single quotes.
 
Error on Execute Update Statement

Thanks for the suggestion, but I have to store this as text becaue I am first importing the values as text from a spreadsheet and I get an error if I try to input in to the table with a numeric value.

Is there an easier way to add the value to the table/query besides the Execute/Update?
 
The error you say you are getting is usually because you have spelled something incorrectly.
 

Users who are viewing this thread

Back
Top Bottom