#USDA nutritional database to SQLite
This script downloads and import the ASCII file version of the USDA National Nutrient Database (Release SR-28) into an sqlite3 database.
The schema strictly followss the USDA reference documentation. The input data are freely available and can be downloaded in https://www.ars.usda.gov/northeast-area/beltsville-md/beltsville-human-nutrition-research-center/nutrient-data-laboratory/docs/sr28-download-files/
Just run the script
$ ./import_usdanlsr28.shAfter the script (quietly) finishes, you will have the file usdanlrs28.sql3 in the working directory.
I plan to introduce a simple web interface to present the nutritional information in a pretty way.
The project is covered by the MIT license.
I started adapting https://github.com/alyssaq/usda-sqlite, but eventually I rewrote everything in order to follow the documentation. I also got some ideas from https://github.com/nmaster/usdanl-sr28-mysql (mostly the name of the project).