SQL update table from another table
Posted
by
LtDan
on Super User
See other posts from Super User
or by LtDan
Published on 2012-09-06T13:18:00Z
Indexed on
2012/09/06
15:41 UTC
Read the original article
Hit count: 201
Using SQL in Access, trying to "Update" a table, with the user name, from another table. The 3rd line below (SQLnm2...) says error-2465 cant find field '|'. I've tried changing the expression many ways but no success. Any assistance would be greatly appreciated.
Dim SQLnm As String
Dim SQLnm2 As String
SQLnm2 = SQLnm2 & "', '" & [Employees]![NBK] & "');"
SQLnm = " Update tbl_DateTracking SET NBK = "
SQLnm = SQLnm & "'" & SQLnm2 & "' WHERE "
SQLnm = SQLnm & "CaseId = '" & CaseId & "' AND OCC_Scenario = '" & OCC_Scenario & "';"
DoCmd.RunSQL SQLnm
© Super User or respective owner