This might be happening because the default for SAS Studio is to set: options VALIDVARNAME=any; At the beginning of your…