Hi everybody! I have two large datasets that lies in the companys database and I want to join these to another dataset that I have from before in SAS. These two large datasets contains information about the same account on different dates. What I want to do is join the latest record of a account from both datasets to the first dataset, but I find that the ways I have done this to now is very inefficient and takes forever. Is there a good way to do this efficient in proc sql? This is the way I have tried to this for only one dataset is something like this, but this is very slow: proc sql; create table Loans as select a.*, b.* FROM customer_information as a inner join ( Select * From Business.LOAN_INFORMATION Group by ACCOUNTNR Having DATE_OF_RECORD=max(DATE_OF_RECORD) ) as b on a.ACCOUNTNR = b.ACCOUNTNR; ; quit;
... View more