We help IT Professionals succeed at work.

SQL Update Syntax

124 Views
Last Modified: 2018-09-17
Would like to update all the values  in a table (tOffice) to False (-1) for the field name "Courier"

I've tried some variations of this SQL command without luck

DoCmd.RunSQL "UPDATE toffice SET Courier  =  -1

Courier is a yes/no variable.

What is wrong with my syntax?  Should I be using an SQL update for this?
Comment
Watch Question

SQL Server DBA & Architect, EE Solution Guide
CERTIFIED EXPERT
Awarded 2009
Distinguished Expert 2019
Commented:
This one is on us!
(Get your first solution completely free - no credit card required)
UNLOCK SOLUTION
NorieAnalyst Assistant
CERTIFIED EXPERT
Commented:
This one is on us!
(Get your first solution completely free - no credit card required)
UNLOCK SOLUTION

Author

Commented:
Thanks!
NorieAnalyst Assistant
CERTIFIED EXPERT

Commented:
No problem, by the way you can actually use No/False.
DoCmd.RunSQL "UPDATE toffice SET Courier  =  No"

Open in new window


DoCmd.RunSQL "UPDATE toffice SET Courier  =  False"

Open in new window

Unlock the solution to this question.
Join our community and discover your potential

Experts Exchange is the only place where you can interact directly with leading experts in the technology field. Become a member today and access the collective knowledge of thousands of technology experts.

*This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.

OR

Please enter a first name

Please enter a last name

8+ characters (letters, numbers, and a symbol)

By clicking, you agree to the Terms of Use and Privacy Policy.