- Go to the PostgreSQL official website, download section for Windows http://www.postgresql.org/download/windows/
- Click on the download installer from EnterpriseDB
- Choose the latest version to download. It takes few minutes to complete the download.
- Install PostgreSQL step by step
Double Click on the installer file, an installation wizard will appear than Click Next .
Enter the Password for the Database superuser and service account then Click Next.
Enter the Port for PostgreSQL, Make Sure that no other application are using this port . leave it as default if you are unsure then click next.
Choose the default locale used by the database , you are completed providing for information the PostgreSQL installer, click next Button to install PostgreSQL.
Click button Finish to Completed the PostgreSQL installation.
- Chang Port in PostgreSQL
- go to folder location install PostgreSQL .C:\Program Files\PostgreSQL\10\data. then find postgresql.conf file open this file, then find port to change it.
2. go to run Service.msc and restart postgresql service.
- Change Default User and Password in PostgreSQL
- change default username :
update pg_authid set rolname ='new_username' where rolname = 'postgres';
- change password :
ALTER USER <username> WITH PASSWORD '<new_password>';