i have the following statement and i don't know where my errror is?
can you help pleasE?
thank you
UPDATE ADPU_Daten_Calcvals
SET
[sum_Failures_B_monthly(excl)] =
( select sum(SUpdateColSource1)
FROM (select distinct offline_date,Bereich,Failures_Bereich_exklNA
as SUpdateColSource1 from ADPU_Daten_Calcvals) a group by
a.Bereich,month(a.Offline_date),YEAR(a.Offline_date))
seems your distinct returns more than one result set.
UPDATE ADPU_Daten_Calcvals
SET
[sum_Failures_B_monthly(excl)] =
(
select top 1 sum(SUpdateColSource1)
FROM (
select distinct offline_date,Bereich,Failures_Bereich_exklNA as SUpdateColSource1
from ADPU_Daten_Calcvals) a group by
a.Bereich,month(a.Offline_date),YEAR(a.Offline_date))