I'm trying to understand someone else's code, and it's getting this error:Msg 8153, Level 0, State 1Warning: Null value is eliminated by an aggregate or other SET operation.What does that mean? I tried doing a search but no one seems explain it in plain English.Here's the query, in case it helps:SELECT a.c_id , a.u_id , a.visit_date , [last_trans] = MAX(t.trans_date)FROM #AddLastTrans aLEFT JOIN Trans t ON a.c_id = t.c_id AND a.u_id = t.u_id AND a.visit_date >= t.trans_dateGROUP BY a.c_id , a.u_id , a.visit_date
I think they're trying to get the most recent transaction for each visit, but it seems like whoever wrote the script (they're not here anymore) ignored or didn't notice the warning message and just kept going. Oh, and all of the fields involved are NOT NULL.Any idea what the error is? Thanks!