top of page

Automatic System

           in Python

Publish Date

4/3/2020

Dedicating data from web and insert into database system.

This page provides the steps of setting up the Automatic System by  Sara Huang and an engineer Richard Wu

Front Setting.

  1.  Create Table in PostgreSQL database.​
    ~$psql -d TRY -U custom < ETFtable.sql

  2. ETFtable.sql


 

 

Screen Shot 2020-04-03 at 12.27.24 PM.pn

Fetch Data from Web.

Screen Shot 2020-04-03 at 12.34.27 PM.pn
Screen Shot 2020-04-03 at 12.34.53 PM.pn
Screen Shot 2020-04-03 at 12.34.42 PM.pn

file TakeETF.py


 

 

Screen Shot 2020-04-03 at 12.35.03 PM.pn

Insert Data to Database.

file InsertETF2Table.py


 

 

Screen Shot 2020-04-03 at 3.07.39 PM.png
Screen Shot 2020-04-03 at 3.10.50 PM.png
Screen Shot 2020-04-03 at 3.07.46 PM.png

Final Setting.

Crontab Setting:

  1. Set Crontab TakeETF.py for every weekday 3PM

  2. Set Crontab InsertETF2Table.py for everySaturday.py 6PM


 

 

Further Improvement.

File change notify insert data into database after successfully download files from website.

Using module "inotify" ​​


 

 

WHAT I BELIEVE

“Motivation is what gets you started. Habit is what keeps you going” 

—  Jim Rohn

© 2020 by Sara Huang. Proudly created with Wix.com

bottom of page