Created
July 16, 2015 23:43
-
-
Save ajmcmiddlin/addef229975cf6676ce2 to your computer and use it in GitHub Desktop.
Dump Access database to CSVs with mdbtools
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env bash | |
db="$1" | |
out_dir="$2" | |
tables="$(mdb-tables -1 "$db")" | |
echo "$tables" | while read t; do | |
mdb-export "$db" "$t" > "${out_dir}/${t}.csv" | |
done | |
exit 0 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment