syntax question for db.Execute Update

  • Thread starter Thread starter Heather
  • Start date Start date
H

Heather

I'm trying to update a column (in a table) in a module but
am getting a syntax error when I compile. I'm trying to
set a column value to another column * a value. (example:
dbs.Execute " Update sometble.plannedhrs Set
sometbl.plannedhrs = (sometbl.percent * .375));"

What is the correct syntax
 
You don't need the field name, just the table name, after the Update
statement.

You've also got an extra closing parenthesis:

dbs.Execute " Update sometble Set plannedhrs = ([percent] * .375);"
 
Back
Top