Hi @giri Thank you for posting your question.
There are two networking options for Azure Database for PostgreSQL - Flexible Server. The options are private access (VNet integration) and public access (allowed IP addresses). At server creation, you must pick one option.
Regardless of the networking option that you choose, we recommend that you always use an FQDN as host name when connecting to your flexible server. The server's IP address is not guaranteed to remain static. Using the FQDN will help you avoid making changes to your connection string.
Regards,
Oury