Some messy SAS code