I have a MS Access data base with a table named Orders I need to find all records with
status(Field in Table)"OPEN" after I find them I then need to change "OPEN" to "ORDERED" Can any one give me help on this?
Thanks
Printable View
I have a MS Access data base with a table named Orders I need to find all records with
status(Field in Table)"OPEN" after I find them I then need to change "OPEN" to "ORDERED" Can any one give me help on this?
Thanks
Write this in your code:
DoCmd.SetWarnings False
DoCmd.RunSQL "UPDATE Orders SET Orders.Status = 'ORDERED' WHERE (((Orders.Status)='OPEN'))"
DoCmd.SetWarnings True
You could use the SQL UPDATE
Database.Execute "Update Orders set Orderstatus = 'ORDERED' where Orderstatus= 'OPEN'"
Database.Execute "Update Table set Field = NewValue where Field = OldValue"
------------------
Vincent van den Braken
EMail: [email protected]
ICQ: 15440110
Homepage: http://www.azzmodan.demon.nl