I would like to create two new variables count1 and hours1.
For each job I would like to sum count (ie count1) and sum hours (ie hours1) without including that particular job.
For example, for welder1 I would have count1=11+9+5+11 and hours1=110+120+90+200.
and if your data were too huge for that cartesian join, you could use proc MEANS to get grand, followed by class totals, and digest that summary:[pre]
proc means noprint data= huge_data ;
class job ;
var count hours ;
output sum= ;
data digested ;
retain g1-g2 ;
if _type_ = 0 then do;
g1= count ;
g2= hours ;
count1 = g1 - count ;
hours1 = g2 - hours ;
keep job count1 hours1 ;
Of course, huge is not specific, but I think the cartesian join in SQL will run out of resources before proc MEANS.