[EpiData-list] view deleted records in view data

epidata-list at lists.umanitoba.ca epidata-list at lists.umanitoba.ca
Sat Aug 19 10:46:05 CDT 2006


Henrica,

Codebook will tell you how many deleted records there are, but won't 
show them to you. This count will be useful, but not a guarantee that 
the same records were deleted.

This can be done in Analysis quite easily.

Run the following commands in Analysis (you can create a .pgm file to do 
this to automate the process).
The idea here is to use relate to find the deleted records. The example 
is for 'file1.rec'. I hope the comments make it clear.

set echo off
set read deleted=off
* deleted records will be ignored
set replace datafile=on
* allow overwriting file1del.rec
read file1
* the number of deleted records will be reported

savedata file1del idvar
* this copy will not have the deleted records
* you only need 'idvar', so it will be a small file
close

set read deleted=on
* deleted records will be treated as if they were not deleted

read file1
* the total number of records will be reported

relate idvar file1del
* file1del will be missing the records
* that are marked as deleted records in file1.rec

select idvar1 = .
* idvar1 comes from file1del.rec
* and will be missing for deleted records

echo The following ID numbers were deleted from FILE1.REC
list idvar

close
* restore default settings
set replace datafile=off
set read deleted=off
set echo=on

Jamie Hockin
Public Health Agency of Canada

Henrica wrote:
> Now I have an issue around deleted records. Is
> there a fast way that the data entry supervisor can find the deleted
> files in a record? When I use "document" "view data" I do not see which
> records are deleted. I think I am probably overlooking something. Is
> there a way to make the deleted records quickly visible (without having
> to go through all of them one by one in the entry mode)?
>   



More information about the EpiData-list mailing list