When migrating an Azure Database for PostgreSQL PaaS resource from a subscription under tenant ABC to another under tenant XYZ, please note that a direct "move" of the resource is not supported, as the process requires transitioning between Azure Active Directory tenants.
In such scenarios, the recommended method is to perform a data migration using one of these approaches:
Azure Database Migration Service (DMS): This service is purposefully designed to handle migrations across different subscriptions and tenants. It simplifies the process by creating a migration project that transfers your database with minimal downtime while ensuring data integrity. With much of the process automated, DMS is typically the preferred and most efficient option.
Backup and Restore (pg_dump/pg_restore): Alternatively, you can export your PostgreSQL database using tools like pg_dump and then restore it into a newly created Azure Database for PostgreSQL instance in the target subscription. This method offers more control but generally involves additional manual steps and may lead to longer downtime compared to DMS.
In summary, for a smoother and more cost-effective migration with minimal disruption, Azure Database Migration Service is generally the most suitable option for transferring your PostgreSQL databases across subscriptions and tenants.
Please let me know if you need any further details or assistance.