Syntax error on simple update query
本问题已经有最佳答案,请猛点这里访问。
我这里有两张桌子。
表1:
1 2 3 4 | **ID** **Color** **Description** 1 red It's red` 2 blue yeah 3 blue blue |
表2:
1 2 3 4 | **ID** **Family** 1 family1 2 family1 3 family2 |
所以我想分解表2,只需在表1的末尾添加
1 2 3 4 5 | UPDATE table1 SET Table1.family = table2.family FROM table1 INNER JOIN table2 ON table1.ID = table2.id; |
我得到了
联合更新的MS访问语法如下:
1 2 3 | UPDATE table1 INNER JOIN table2 ON table1.ID = table2.id SET table1.family = table2.family |
试试这个:
1 2 | UPDATE table1 INNER JOIN table2 ON table1.id = table2.id SET table1.family = table2.family; |
您的语法错误,访问时使用:
1 2 3 | UPDATE table1 INNER JOIN table2 ON table1.ID = table2.id SET Table1.family = table2.family; |