How to seed a Rails database with a CSV file
First, Create a folder inside of
Put your CSV file
example.csv into the
lib/seeds folder. In the example below, the file is called
Make sure you've created a resource with the appropriate columns to match your seed data. The names don't have to match up.