I need to update the Notes field in my table tblMain by concatenating the text data with the Notes field in my secondary table tblSecond by matching the ID field in both tables.
I was using the following SQL:
UPDATE tblMain
SET tblMain.Notes = (tblMain.Notes + (SELECT DISTINCT Notes FROM tblSecond
WHERE tblSecond.ID = tblMain.ID))
but I get the following error
Subquery returned more than 1 value.
presumably because the SELECT statement is returning an entire resultset.
How would I perform this operation successfully?
It will handle if subquery returns more than 1 value.