1. Creating the Database

The MongoDB database was named reficio, the same name as this site from which the information is extracted. The following command sequence creates an empty database, destroying the current database, if it exists.

// Using, droping, and re-creating the reficio database
use reficio;
db.dropDatabase();
use reficio;

Execution of these commands in the mongo shell:

$ mongo
MongoDB shell version v3.6.4
connecting to: mongodb://127.0.0.1:27017
MongoDB server version: 3.6.4
> // Using, droping, and re-creating the reficio database
> use reficio;
switched to db reficio
> db.dropDatabase();
{ "dropped" : "reficio", "ok" : 1 }
> use reficio;
switched to db reficio
>

Integration of MongoDB with WordPress