Skip to content
This repository has been archived by the owner on Aug 26, 2024. It is now read-only.

Doesn't fail if id is not unique #23

Open
ckrf opened this issue Jan 6, 2016 · 1 comment
Open

Doesn't fail if id is not unique #23

ckrf opened this issue Jan 6, 2016 · 1 comment

Comments

@ckrf
Copy link

ckrf commented Jan 6, 2016

With a single id() variable that has duplicates, readreplace runs to completion instead of failing with an error.

@matthew-white
Copy link
Collaborator

This was a feature of readreplace version 1, which I maintained in version 2 for backwards compatibility reasons (see #22). readreplace completes all replacements in the replacements file in order, so if the id() variables aren't unique in the replacements file, the data set in memory will finish with the last replacement for each ID combination. The id() variables definitely aren't required to be unique in the data set in memory, as there are use cases outside data entry where users want to complete bulk replacements, completing the same replacement for multiple observations.

However, I could see this being a useful check for the replacements file. Maybe you could work with @boyercb on a pull request!

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants