See the documentation here: https://docs.mendix.com/howto/data-models/migrating-your-mendix-database/#41-exporting-a-postgresql-database
Regards,
Ronald