Hello,
I have a dataset that looks like this:
I would like to sum the column "flow" when year, orig and dest have the same value. For instance, in that example, the dataset should become:
Is there a simple way to do this?
Post test data in the form of a datastep!
proc sql; create table WANT as select YEAR, ORIG, DEST, sum(FLOW) as FLOW from HAVE group by YEAR,ORIG,DEST; quit;
As a guess.
View solution in original post
It's your turn to help shape SAS Innovate 2027. Share your expertise and inspire the SAS community.
Submit your proposal →
Check out this tutorial series to learn how to build your own steps in SAS Studio.
Find more tutorials on the SAS Users YouTube channel.
Ready to level-up your skills? Choose your own adventure.
Browse our catalog!