# Redux Tutorial: Load sample data

To seed the database with sample data run the following command:

$ npm run load-sample -s

The output should look something like this:

Setup db.reduxtest with "todos" collections
Cleared "todos" collections
Finished creating sample todos

The above command stores the sample data into the reduxtest database. You can check if the sample data loaded correctly by launching the "mongo" client and switching to the reduxtest database. Once switched, you can query the todos collection to inspect the loaded sample data:


$ mongo
MongoDB shell version: 3.2.8
connecting to: test
> use reduxtest
switched to db reduxtest
> db.todos.find()
{ "_id" : ObjectId("579cba15d8baed3b01b2a8f4"), "todo" : "Prepare new Billing format", "completed" : false }
{ "_id" : ObjectId("579cba15d8baed3b01b2a8f5"), "todo" : "Create benefits presentation", "completed" : false }
{ "_id" : ObjectId("579cba15d8baed3b01b2a8f6"), "todo" : "Prepare productivity report", "completed" : false }
{ "_id" : ObjectId("579cba15d8baed3b01b2a8f7"), "todo" : "Review non-exempt evaluations", "completed" : false }
{ "_id" : ObjectId("579cba15d8baed3b01b2a8f8"), "todo" : "Update insurance information", "completed" : false }

Now that we have seeded our database with sample data, we can define some database functions which we will access from our GraphQL service.