How to import a schema sql file using pgadmin 4?
It worked like this for me:
- Go to your Database and click on this.
- Click in the menubar on
Tools
,Query Tools
- Then it reload the page. Above the menubar on the left, you see the folder-icon (look picture below). Click on them and choose your
.sql
file - Click on
select
and the file is uploaded - To execute the
.sql
file, press F5 or the play button above the menubar in the middle (look at the screenshot below). - Right click on your database and click on 'Refresh'.
Following are the step that will help you in importing all tables of your schema
1) Open pgAdmin 4
2) Navigate to Your Database Name --> Schemas --> public
3) Then right click on public
4) After clicking on public then select Restore option from DropDown Menu
5) A window will open in which you only have to give location of .sql file and leave other textboxes
6) Click Restore and leave rest on pgadmin
Note :You have to perform these steps for every single table you want to import