On Apr 29, 6:57 pm, "Douglas J. Steele"
<NOSPAM_djsteele@NOSPAM_canada.com> wrote:
Sorry, I didn't look closely enough at your SQL.
What are [ID] and [StatusCodeTemp]?
To get their values (rather than their names) into the SQL statement, you
need something like:
stSQL = "INSERT into Status (StatusCompany, StatusCode) " & _
"Values (" & [ID] & ", '" & [StatusCodeTemp] & "')"
There, I'm assuming StatusCompany is a numeric field, and StatusCode is a
text field. Check the quotes in the Values line. Exagerated for clarity,
that's
"Values ( " & [ID] & ", ' " & [StatusCodeTemp] & " ' ) "

Signature
Doug Steele, Microsoft Access MVP
http://I.Am/DougSteele
(no e-mails, please!)
> When I used the new code, I got the following error:
>
[quoted text clipped - 5 lines]
>
> What are we missing?
On Apr 29, 6:57 pm, "Douglas J. Steele"
<NOSPAM_djsteele@NOSPAM_canada.com> wrote:
>> The best way is
>>
[quoted text clipped - 11 lines]
>>
>> End Sub
magmike - 30 Apr 2008 20:45 GMT
On Apr 30, 2:02 pm, "Douglas J. Steele"
<NOSPAM_djsteele@NOSPAM_canada.com> wrote:
> Sorry, I didn't look closely enough at your SQL.
>
[quoted text clipped - 46 lines]
>
> - Show quoted text -
That did it. Actually, though, both fields are number fields.