Check out example codes for "psql load dump". It will help you in understanding the concepts better.

Code Example 1

psql databasename < data_base_dump

Code Example 2

pg_dump dbname > outfile

Learn ReactJs, React Native from akashmittal.com