Hi All,
I am attempting to update a main items table with the last record results from another table.
In the follow example, the SELECT statement provides the result - i.e. the last item in the Details table.
Code:
UPDATE Tbl_WorkflowItems
SET CurrentTask = (
SELECT TOP 1 d.TaskName
FROM Tbl_WorkflowDetails d
WHERE d.WorkFlowID=27 AND d.Completed=True
ORDER BY d.ItemNumber DESC)
WHERE ID = 27
However, the error I'm receiving is Operation must use an updateable query.
The query is very clearly an update query. Both tables can be updated. So what gives?
Thanks in advance for any good help
Cheers