Loading Data from MySQL database to Snowflake
using Matillion
Step 1: Launch MySQL database in AWS using RDS service
Step 2: Load sample data to MySQL database
Step 3: Fetch data from MySQL table & load into Snowflake
1. Launch MySQL database in AWS using RDS service:
Follow below step to launch MySQL RDS database in AWS:
2. Load sample data to MySQL database:
a. Download sample dataset from https://github.com/datacharmer/test_db
b. copy file from local machine to matillion’s ec2 using WinSCP tool
c. unzip test_db-master.zip
d. cd /home/centos/test_db-master
e. install mysql client on ec2 using “sudo yum install mysql” command
f. check if mysql client installed successfully or now using “mysql –version”
command
g. load employees data using “mysql -h <red-mysql-endpoint> -P 3306 -u admin
-p -t < employees.sql” command
h. enter password for “admin” user when prompted
i. login to mysql & check for sample data using using “mysql -h <red-mysql-
endpoint> -P 3306 -u admin -p” command & enter password when prompted
3. Fetch data from MySQL table & load into Snowflake:
Use “RDS Query” component to load data from MySQl table to Snowflake