Import/Export DB via Terminus

Read time: 4 minutes

User Profile

Hamad K

Jan 18, Thu

Mastering Database Magic: Importing and Exporting Dummy Databases Like a Wizard:

​​In the enchanting realm of databases, mastering the art of importing and exporting dummy databases is akin to wielding powerful spells. In this magical guide, we'll explore the incantations required to seamlessly move your toy dragons (dummy databases) between mystical locations, be it from your magic castle to a secret garden or vice versa.


Importing a Dummy Database:


Step 1: Open Your Wizard’s Book (Terminal):

To embark on your mystical journey, open the wizard’s book—Terminal, the gateway to the arcane world of databases.


Step 2: Cast the Command Spell:


Type the following command to summon the magic necessary for importing your toy dragon:

mysql -u wizard -p magiccastle < /path/to/dummy_database.sql

Replace 'wizard' with your actual username and 'magiccastle' with your database name. The path /path/to/dummy_database.sql should be the location where your precious toy dragon resides.


Exporting a Dummy Database:


Step 1: Keep Your Wizard’s Book Open (Terminal):


Ensure that your wizard’s book (Terminal) remains open as you prepare to send a toy unicorn (data) to a secret garden (backup file).


Step 2: Conjure the Command Spell:


Type the following command to unleash the magic of exporting your toy unicorn:

mysqldump -u wizard -p magiccastle > /path/to/secret_garden/backup.sql


Just as before, replace 'wizard' with your username, 'magiccastle' with your database name, and adjust the path /path/to/secret_garden/backup.sql to where you want to store the backup.


Step 3: Whisper the Magic WordPress:


Enter and whisper the magic word (password) when prompted. Your wizardry will seamlessly transfer the toy unicorn to your secret garden, ready to be summoned when needed.

Interested in Publishing your knowledge and sharing it with the world?

Or ask anything about our services

We thrive by partering with visionary brands and driven individuals.

Say hello 👋

[email protected]