With command-line

Here are the steps to restore a PostgreSQL dump to an Amazon RDS database:

  1. Create an RDS instance with PostgreSQL compatibility, if you don’t have one.

  2. Connect to your RDS instance using the psql command-line client or a PostgreSQL-compatible tool of your choice.

  1. Create the database on RDS by running the following command:
  1. Use the following command to import the PostgreSQL dump file to the newly created database:
  1. Replace [RDS_ENDPOINT], [USERNAME], [DATABASE_NAME], and [SQL_DUMP_FILE] with the appropriate values for your RDS instance and the PostgreSQL dump file you want to import.

  2. When prompted, enter the password for the user specified in the command.

  3. Once the import process is completed, you should be able to see the imported data in your RDS PostgreSQL database.

Note that the format of the dump file should be in pg_dump format.