i have two tables a_daily and o_daily_lcsgeneration:
i am trying this query :
update a_daily
set
a_daily.Turbine_Generation =
(
select sum(o_daily_lcsgeneration.Turbine_Generation)
from o_daily_lcsgeneration
where o_daily_lcsgeneration.Location = 1
group by o_daily_lcsgeneration.Date
)
but received the above error saying sub query more than 1 row
remove the
GROUP BYclauseit causes the query to return more than one value of you have multiple dates.
UPDATE 1
or