BookmarkSubscribeRSS Feed
AndrasJonas
Calcite | Level 5

Dear SAS Community,

We are having an odd issue. One of the formats exported is SAS.

SAS Viewer will show displaying records 1-279 of 305 but the 26 records are never to be found.

As the data table is growing, this missing set of records is always there in the count but not viewable.
It is not due to paging, and we went through the data and could not find anything special about those.

Here is the specific example:

count_issue.png

 

No matter what, that 26 difference will remain. And those records are missing from the SAS file. But oddly, it says the number of records is 305.


Any idea what could be the issue here please?

All the Best,
András

2 REPLIES 2
AllanBowe
Barite | Level 11

Perhaps they are deleted records?  In datasets, deleted observations are simply marked as such, they are not physically removed unless the dataset is rebuilt.

 

You can test if this is the case by compiling this macro:  https://core.sasjs.io/mf__getattrn_8sas_source.html

 

And running the following code:

%put All Observations=%mf_getattrn(YOURDATASET,NOBS);
%put Non-Deleted (Logical) Observations=%mf_getattrn(YOURDATASET,NLOBS);

 

/Allan
SAS Challenges - SASensei
MacroCore library for app developers
SAS networking events (BeLux, Germany, UK&I)

Data Workflows, Data Contracts, Data Lineage, Drag & drop excel EUCs to SAS 9 & Viya - Data Controller
DevOps and AppDev on SAS 9 / Viya / Base SAS - SASjs
SASKiwi
PROC Star

Try running a simple DATA step to recreate the dataset.  Test first by writing to a new dataset. If that fixes your problem overwrite the original dataset

 

data MyLib.new;
  set MyLib.old;
run;

data MyLib.old;
  set MyLib.old;
run;

sas-innovate-2024.png

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 connect to databases in SAS Viya

Need to connect to databases in SAS Viya? SAS’ David Ghan shows you two methods – via SAS/ACCESS LIBNAME and SAS Data Connector SASLIBS – in this video.

Find more tutorials on the SAS Users YouTube channel.

Discussion stats
  • 2 replies
  • 432 views
  • 0 likes
  • 3 in conversation