Skip to content

Conversation

@gorcha
Copy link
Contributor

@gorcha gorcha commented Jan 7, 2026

This PR fixes an error when reading SAS files with zero observations (see tidyverse/haven#627). When there are zero observations SAS appears to write string variables with a default width of 0, which was throwing an error in sas7bdat_validate_column().

I've removed the check for width == 0 since this is allowed by SAS and the zero observation data file loads successfully so this check seems unnecessary.

@evanmiller evanmiller merged commit 4d3c7f7 into WizardMac:dev Jan 7, 2026
11 of 12 checks passed
@evanmiller
Copy link
Contributor

Thanks!

@gorcha gorcha deleted the sas-zero-obs branch January 7, 2026 14:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants