if those datasets have the same shared variables, just simply use MERGE and BY. If they need to be merged by different variable, you might need to use macro to help. check the paper here for the detail. http://support.sas.com/resources/papers/proceedings11/409-2011.pdf