SAS suggested changes

Simplification of SAS extract code