BookmarkSubscribeRSS Feed
Calcite | Level 5

Finyear        Value1        value2             Percentage

20142015     26469        421596             6%

20142015     370644      14582164         2%

20152016    108747        643178             16%

20152016     1259525     17519233          7%


My Query is: I am getting percentage row level wise but when i am trying to sum up finyear wise i.e. vertically

the value is changing , means i am not getting result after aggregation.

Kindly provide me solution regarding this.



Harsh Patel

Jade | Level 19

Please post the desired output and code used to calculated the percentages.

Calcite | Level 5

Row level division calculation is possible in EG but we want to show output in SAS VA which should be aggregated but  right now it shows the summation of the row level in EG.

Kindly suggest some solution.

Finyear                         State                           City                       income               expense         expratio

20142015                     Guj                              Ahmd                    100                      80                 0.8

20142015                     Guj                              Vadodara               200                     150               0.75

20142015                     Maharashtra               Mumbai                  250                     200               0.8

20142015                     Maharashtra               Pune                      200                      100               0.5

20152016                     Guj                              Ahmd                    150                       100              0.66

20152016                     Guj                              Vadodara              120                      100               0.83


We want to show this data in SAS va.  If the user  does not select any filters the column should show overall expratio, if he selects particular state it should show expratio of that particular state.If they select state and city it should show accordingly.



Harsh Patel


Available on demand!

Missed SAS Innovate Las Vegas? Watch all the action for free! View the keynotes, general sessions and 22 breakouts on demand.


Register now!

How to Concatenate Values

Learn how use the CAT functions in SAS to join values from multiple variables into a single value.

Find more tutorials on the SAS Users YouTube channel.

Click image to register for webinarClick image to register for webinar

Classroom Training Available!

Select SAS Training centers are offering in-person courses. View upcoming courses for:

View all other training opportunities.

Discussion stats
  • 2 replies
  • 2 in conversation