Precise Steps to Transfer Data from MySQL to PostgreSQL using DBeaver:
1. Connect to MySQL in DBeaver
- Open DBeaver.
- Click Database > New Database Connection.
- Select MySQL, click Next.
- Enter:
- Host:
sourcedb-vicclasses.j.aivencloud.com - Port:
19774 - User:
avnadmin - Password:
AVNS_DSKQiqnqWhlGSqkqB-R - Database:
defaultdb
- Host:
- Test connection and click Finish.
2. Connect to PostgreSQL in DBeaver
- Database > New Database Connection.
- Select PostgreSQL, click Next.
- Enter:
- Host:
172.178.131.221 - Port:
5432 - User:
luxds - Password:
1234 - Database:
warehouse
- Host:
- Test connection and click Finish.
**
- Export Data from MySQL**
- Right-click the MySQL table
houses_for_rent_reinny. - Select Export Data.
- Choose Database as target.
- Click Next.
4. Set PostgreSQL as Target
- Select the PostgreSQL connection (
warehouseDB). - Choose the staging.house_for_rent_reinny table (or create if not exists).
- Make sure column mapping matches:
id,title,location,size,price.
5. Configure Export Options
- Check Truncate before load if you want to clear data first (optional).
- Make sure
ON CONFLICT DO NOTHINGoption is respected (DBeaver might not natively support this; handle duplicates later if needed). - Click Next.
6. Execute Transfer
- Review preview.
- Click Start to transfer.
- Wait until data is loaded and verify completion message.
7. Verify in PostgreSQL
- Right-click staging.house_for_rent_reinny table under PostgreSQL connection.
- View Data > All Rows.
- Confirm data matches top 10 rows from MySQL.