0

So I have two tables, InTheMiddle and Table2.
The 1st one contains Name column, the 2nd one contains ID and Name columns.
(they also have other columns, but irrelevant to this question)

I want to update/change the names in the 1st table with the IDs from the second one, but of course only when the names match and there's only one name (so there aren't any semicolons ";").

Here's a query that I tried to use, but Access tells me "Operation must use an updateable query"

UPDATE InTheMiddle
SET [Name] =
(SELECT [Table2].ID
   FROM [Table2]
   WHERE InTheMiddle.[Name] = [Table2].[Name]
   AND InTheMiddle.[Name] NOT LIKE "*;*"
);
pkrysiak
  • 182
  • 5
  • 14

1 Answers1

0

Possible duplicate to Operation must use an updatable query. (Error 3073) Microsoft Access, in which the accepted answer suggests that the only way to avoid that error message is to use temporary tables.

Besides the accepted answer, this answer suggests a workaround to code looking like yours

Community
  • 1
  • 1
Serenthia
  • 1,222
  • 4
  • 22
  • 40