I am using SAS EG 7.1 on the server installed with SAS 9.4.
The codes could be run on SAS9.3. But got the error:
ERROR 22-322: Syntax error, expecting one of the following: ;, CYCLEATTRS, DATA, DATTRMAP, DESCRIPTI.
The codes in the eiditor is like:
proc sgplot data=out_data(where=(pd_Seg='Term')) pctlevel=group;
vbar dist_yyq/ response=dist_yearqr stat=percent name="vbar" grouporder=ascending
group=ltv_grp;
keylegend "vbar"/sortorder=ascending;
xaxis fitpolicy=thin;
run;
What is the problem? Is that caused by running 9.4?
Earlier versions of SAS 9.4 didn't recognize option sortorder= in the keylegend statement.
Solve errors in the order in which they appear. Fixing the first error will often remove many subsequent error messages.
In the future, use the {i} tool to paste SAS output, it provides better formatting.
SAS Innovate 2025 is scheduled for May 6-9 in Orlando, FL. Sign up to be first to learn about the agenda and registration!
What’s the difference between SAS Enterprise Guide and SAS Studio? How are they similar? Just ask SAS’ Danny Modlin.
Find more tutorials on the SAS Users YouTube channel.
Ready to level-up your skills? Choose your own adventure.