i am trying to use this technique in a subset of the original data , however i've the following issue WARNING: In a call to the CATX function, the buffer allocated for the result was not long enough to contain the concatenation of all the arguments. The correct result would contain 336 characters, but the actual result might either be truncated to 200 character(s) or be completely blank, depending on the calling environment. The following note indicates the left-most argument that caused truncation. i am using the macro below and having a lot of key variables instead of ID and Key. Any idea how to support length ( greater than 200 ) ? %macro agg (in=, out=, N_segments=) ; %local X seg ; %let X=1+mod(input(char(MD5(catx(":",ID,Key)),10),pib1.),&N_segments) ; %do seg = 1 %to &N_segments ; proc sql; create table seg as select ID, Key, sum(Var) as SUM, count (distinct Var) as UCOUNT from &in where &X = &seg group ID, Key; quit; proc append base=&out data=seg; run; %end ; %mend ; %agg (in=Trans, out=Agg, N_segments=3)
... View more