I'll do the best I can with the code samples.... Here is my code (just a small part of the program): 545 if substr("&imember",11,1) = 'A' and length(account_number) ge 10 then do; 546 if substr(account_number,10,1) = '-' then substr(text,14,12) = account_number; 547 else do; 548 substr(text,14,9) = substr(account_number,1,9); 549 substr(text,23,1) = '-'; 550 substr(text,24,2) = substr(account_number,10,2); 551 end; 552 end; 553 554 if substr("&imember",11,1) = 'C' then do; 555 substr(text,14,12) = account_number; 556 substr(text,26,1) = ' '; 557 substr(text,35,1) = ' '; 558 end; 559 560 substr(text,27,8) = trade_date; 561 And this is how my log looks (sort of): if substr("46TR092911A.xls",11,1) = 'A' and 46 + length(account_number) ge 10 then do; if substr(account_number,10,1) = '-' then substr(text,14,12) = account_number; else do; substr(text,14,9) = substr(account_number,1,9); substr(text,23,1) = '-'; substr 47 +(text,24,2) = substr(account_number,10,2); end; end; if substr("46TR092911A.xls",11,1) = 'C' then do; substr(text,14,12) = account_number; substr(text,26,1) = ' '; substr(text,35,1) = ' '; end; substr(text,27,8 48 +) = trade_date; transaction_type = upcase(transaction_type); if transaction_type =: 'B' then trans_type = '100'; else if transaction_type =: 'S' then trans_type = '690'; else if transaction_type =: 'E' then trans_type = '400'; else if Which makes it rather hard to read. The text seems to loose all syntax. It actually goes beyond the right side of my screen in the SAS log window. (Here it seems to wrap within this window). It's not a big problem, but it is a pain in the backside.
... View more