Thank you for reaching out.
In addition to Umar's answer below. To connect your Azure SQL Database within a private network or office network, you can use Azure Private Endpoint. Tutorial: Connect to an Azure SQL server using an Azure Private Endpoint using the Azure portal.
Whitelisting a public IP address involves adding it to the server firewall rules in the Azure portal, ensuring secure access to your Azure SQL Database from your office network. Azure SQL Database and Azure Synapse IP firewall rules.
Regards,
Oury