Skip to content

Import data SSH #451

Answered by orware
mwerder asked this question in Q&A
Apr 27, 2023 · 2 comments · 1 reply
Discussion options

You must be logged in to vote

Hello @mwerder,

This should be possible if you already have the SQL dump file handy.

Typically what we recommend in these cases is to use our pscale CLI and the shell command to get to a MySQL shell for your PlanetScale database first.

Once you have a MySQL shell open, you can then use a command like the following one to import your dump file into your PlanetScale database:

source <YOUR_DUMP_FILE>.sql;

I've also been able to import dump files via MySQL GUI clients like DBeaver too.

When importing dump files there are a few caveats to be aware of as sometimes the dump file may have everything wrapped in a START TRANSACTION; / COMMIT; transaction which will result in the import timing out i…

Replies: 2 comments 1 reply

Comment options

You must be logged in to vote
1 reply
@orware
Comment options

Answer selected by mwerder
Comment options

You must be logged in to vote
0 replies
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants