This is where some SAS is interjected into SQL syntax for PROC SQL, namely the SAS dataset options. Try this
replace this
/*...*/ from PSAEU11.db_dossier sousc (where sousc.cd_dossier = 'SOUSC' and sousc.lp_etat_doss not in ('ANNUL','A30','IMPAY') and sousc.no_police = 'I99300001') left join /*...*/
with this
/*...*/ from PSAEU11.db_dossier (where=(cd_dossier = 'SOUSC'
and lp_etat_doss not in ('ANNUL','A30','IMPAY')
and no_police = 'I99300001')) as sousc left join /*...*/
This little example works as well
proc sql;
select cars.Make, cars.model
from SASHELP.CARS(where=(Make="Audi")) as cars;
quit;
... View more