Import SQL dump into PostgreSQL database
Here is the command you are looking for.
psql -h hostname -d databasename -U username -f file.sql
psql databasename < data_base_dump
That's the command you are looking for.
databasename must be created before importing.
Have a look at the PostgreSQL Docs Chapter 23. Backup and Restore.