DATA Step, Macro, Functions and more

Number of observations is changing by 9,999 without running any code!!

Accepted Solution Solved
Reply
Occasional Contributor
Posts: 18
Accepted Solution

Number of observations is changing by 9,999 without running any code!!

Please help, I created a permanent dataset with 454,243 observations.
I used this to create a tempory dataset with a simple set statement, no conditions or clauses or anything... and the tempory dataset had only 444,244 observations! Less 9,999. This happened in SAS EG, so I wanted to try this in PC SAS....

I opened the permanent dataset in PC SAS and found it to have 464,242 observations!!! Plus 9,999 compared with the original!!!

Then the tempory dataset which I created had the same number (464,242), which restores my faith in the "set" statement!!!

What is happening?  I am not new to SAS and have never experienced this before. My collegues are also bewildered. They checked my code and agree it seems fine!!


Accepted Solutions
Solution
‎10-01-2014 07:11 AM
Super User
Posts: 6,982

Re: Number of observations is changing by 9,999 without running any code!!

Look at SAS(R) 9.2 Language Reference: Dictionary, Fourth Edition

You may have an option set that reduces your number of observations with every step. (FIRSTOBS=10000)

---------------------------------------------------------------------------------------------
Maxims of Maximally Efficient SAS Programmers

View solution in original post


All Replies
Solution
‎10-01-2014 07:11 AM
Super User
Posts: 6,982

Re: Number of observations is changing by 9,999 without running any code!!

Look at SAS(R) 9.2 Language Reference: Dictionary, Fourth Edition

You may have an option set that reduces your number of observations with every step. (FIRSTOBS=10000)

---------------------------------------------------------------------------------------------
Maxims of Maximally Efficient SAS Programmers
Occasional Contributor
Posts: 18

Re: Number of observations is changing by 9,999 without running any code!!

Thanks!

You're right I was using that option earlier to check my code on a sample dataset!

So grateful, thanks Smiley Happy

🔒 This topic is solved and locked.

Need further help from the community? Please ask a new question.

Discussion stats
  • 2 replies
  • 175 views
  • 0 likes
  • 2 in conversation