Jesse Schutt 1 minute read
June 13, 2019

Importing a PG Dump from the Command Line

Similar to the time formats I wrote about here, I can not seem to remember the syntax for importing a PostgreSQL dump file into a database from the command line!

Fortunately the steps are pretty simple:

  1. Log in to my virtual box - typically Laravel Homestead
  2. Navigate to the directory where the db dump lives
  3. Run the following script, updating values where appropriate
  4. Enter the password for the Homestead user when prompted - normally "secret"