Hallo,

ich komme nicht weiter. Dieses SQL Statement liefert mir die Fehlermeldung 'Nullwerte für Spalte oder Variable TEAT05 nicht zulässig. Wenn ich eine bestimmte soid4 auswähle, die einen Wert enthält, dann funktioniert es. Was mache ich falsch?

update tst01pf t
set t.teat05 = (select ifnull(s.soeipr, 0)
from son01pf s
where t.tetenr = s.soid4
and s.sofa =01
and s.sodtbi >= 161231
and s.soeipr <> 0
and s.soeipr is not null
and s.soid1=30600
and s.sosts = 0)
where t.tefa = 10 and tetenr=11

Gruß

Progras