sas2parquet
The ultimate SAS (.sas7bdat) to Parquet converter — built to handle files that fail with standard tools.
sas2parquet automatically detects encodings, repairs schemas, infers correct data types, and performs pixel-perfect validation between SAS and Parquet outputs.
✨ Features
| Feature | Description |
|---|---|
| 🔄 Auto Encoding | Detects UTF-8, Latin1, CP1252 from metadata or fallback |
| 🧠 Smart Types | Infers datetime, numeric, string with 20+ retry strategies |
| ✅ Validation | Chunk-by-chunk comparison (metadata, counts, values) |
| 📊 Memory Safe | Chunked processing (96GB RAM optimized, configurable) |
| 💾 ZSTD Compression | Level-6 ZSTD for efficient Parquet storage |
| 📝 Detailed Logs | Full conversion trace + mismatch reports |
| 🎯 Two Modes | Single file or recursive directory processing |
🚀 Quick Start
Install
pip install sas2parquet
✅ Usage
Convert a directory (recommended)
sas2parquet path/to/sasdata/
- Converts all
.sas7bdatfiles recursively - Creates
parquetdata/andlogging/next tosasdata/
Convert a single file
sas2parquet path/to/file.sas7bdat
Output (default):
path/to/file.parquet
Specify output location
Directory mode — custom output directory
sas2parquet path/to/sasdata/ --out path/to/parquetdata/
File mode — custom output file
sas2parquet path/to/file.sas7bdat --out path/to/output.parquet
Custom log directory (directory mode)
sas2parquet path/to/sasdata/ --log-dir path/to/logs/
📁 Directory Mode Behavior
your-project/
├── sasdata/
│ ├── file1.sas7bdat
│ └── subfolder/
│ └── nested.sas7bdat
├── parquetdata/
│ ├── file1.parquet
│ └── subfolder_parquet/
│ └── nested.parquet
└── logging/
└── conversion_20260205_1145.log
🛠️ CLI Reference
sas2parquet --help
⚙️ Configuration (Advanced)
Edit constants in:
src/sas2parquet/convert.py
👥 Authors
This package was built collaboratively.
- Zaman Ziabakhshganji — creator and maintainer
- Anete Kristiana Zonnenberga — co-author and contributor
- Farshad Radman — co-author and contributor
- Jos van Dongen — co-author and contributor
📄 License
MIT License
Metadata
Release files for sas2parquet 1.0.9
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| sas2parquet-1.0.9.tar.gz | 8.9 kB | Without provenance | Details for sas2parquet-1.0.9.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| sas2parquet-1.0.9-py3-none-any.whl | Python 3 | none | any | Details for sas2parquet-1.0.9-py3-none-any.whl |
Total release size: 18.9 kB
Release files / sas2parquet-1.0.9.tar.gz
| Download URL | sas2parquet-1.0.9.tar.gz |
|---|---|
| Size | 8.9 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
d0f56d26c37ad9a1002e3f9eb155bde62df47f11d941eb005f521116036c5549
|
|
BLAKE2b-256 checksum How to use checksums |
0892af2f1c62621be3f249fc04056643b05155a7e720d5428fdadb6b1d93e28a
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
poetry/2.3.1 CPython/3.11.0 Darwin/25.2.0
|
Release files / sas2parquet-1.0.9-py3-none-any.whl
| Download URL | sas2parquet-1.0.9-py3-none-any.whl |
|---|---|
| Size | 10.0 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
a2f3bf82e008780ca9f7c5a82433be5fe54f2401de1a58963d11d70e1272be6b
|
|
BLAKE2b-256 checksum How to use checksums |
b9ee410639dea89b5c0a1f87c8dd5cb658c572d50852f9fed2b473dbac57a9da
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
poetry/2.3.1 CPython/3.11.0 Darwin/25.2.0
|
Security for sas2parquet 1.0.9
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.