Skip to content
Yo-An Lin edited this page Apr 26, 2017 · 1 revision

Maghead command line tools provide commands to help you manage the database.

Registering Database

maghead db add --user root --database testing2 testing2 "mysql:host=localhost"

To create the database after registering the database "testing2", simply add the --create option.

maghead db add --create --user root --database testing2 testing2 "mysql:host=localhost"

Creating Database

To create a registered database:

maghead db create testing2 

Removing Database

To remove the registration of the database:

maghead db remove testing2

Please note this command doesn't drop the database. To drop the database before removing the registration, you can add --drop option to drop the database:

maghead db remove --drop testing2