That error has nothing to do with your code.
SAS is complaining about the setting for the LOCALE option.
4 OPTIONS LOCALE=es_419 DFLANG=LOCALE;
______
14
ERROR 14-12: Invalid option value ES_419 for SAS option LOCALE.
Check and see if there is an option or preference setting in SAS/Studio that will let you change that so that SAS/Studio doesn't try to send SAS and invalid value.
... View more