stessa istruzione ma comportamento diverso
As400
UPDATE ANBANCA00F SET B_W_ORDFOR = ifnull( ( select count(*) from anbanpr00f where CD_BANCAL = anbanca00f.COD_BANCAL and DDT_FORNIT = ' ' and lavorato = ' ' ) , 0 ) in anbanca00f un record in anbanpr00f quattro record - se eseguita dentro ad un pgm mi restituisce 1 - in interattivo giustamente 4