Help with SQL update

G

Guest

I have this statement below and can't figure out what is wrong. The item in
repeatHolder is an integer. The table that I want to update the item is
Info. The field is Week2Repeat that I want to update.

When I go to run this is brings up the box asking for repeatHolder to input
the value. But repeatHolder has a value in it. When I go to mouse over
repeatHolder in the statment in debug nothing shows up. But I put in a check
before and when I mouse over repeatHolder it has a value in it before this
SQL statement.

I have no clue what is going on. Does anyone have any insight?

DoCmd.RunSQL "UPDATE Info SET Info.[Week2Repeat] = repeatHolder + 1 WHERE
Info.ResId = '" & Forms![Info]![ResId] & "'"
 
G

Guest

try:
DoCmd.RunSQL "UPDATE Info SET Info.[Week2Repeat] = " & repeatHolder + 1 & "
WHERE Info.ResId = '" & Forms![Info]![ResId] & "'"
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top