BookmarkSubscribeRSS Feed
4john
Calcite | Level 5
Hi,
I am trying to concatenate 10 datasets with variables with same name but with diff.attributes.I tried to concatenate using proc append using force option .But its excluding some observations.How do i concatenate these 10 datasets into one dataset with all the observations present.

Thanks,
1 REPLY 1
sbb
Lapis Lazuli | Level 10 sbb
Lapis Lazuli | Level 10
A DATA step using a SET statement, possibly with a BY (presuming sorted input), however this process could also be problematic, if you attempt to combine / interleave observations using a BY but with a particular "truncated variable" condition, your prior "sorted input" may be compromised.

If you are not concerned about the possibility of truncation, you can concatenate and then sort. Or if you have concerns about truncation, consider coding SAS LENGTH or ATTRIB statements before the SET, so that you establish sufficient SAS variable length attribute so the DATA step processing can complete with desired success that meets your objectives for the final output.

Scott Barry
SBBWorks, Inc.

hackathon24-white-horiz.png

The 2025 SAS Hackathon Kicks Off on June 11!

Watch the live Hackathon Kickoff to get all the essential information about the SAS Hackathon—including how to join, how to participate, and expert tips for success.

YouTube LinkedIn

What is Bayesian Analysis?

Learn the difference between classical and Bayesian statistical approaches and see a few PROC examples to perform Bayesian analysis in this video.

Find more tutorials on the SAS Users YouTube channel.

SAS Training: Just a Click Away

 Ready to level-up your skills? Choose your own adventure.

Browse our catalog!

Discussion stats
  • 1 reply
  • 1090 views
  • 0 likes
  • 2 in conversation