Member-only story

How to Scrape Fire Bureau website via regular expression and importing the data into SQLite?

DigNo Ape
3 min readJan 26, 2023

--

In the website of Fire Bureau of Taichung City Government, it is showing the real-time reporting cases with the info such as location, time, and status. In this session, we are going to study on how to gran this information via Python and store the data into the database of SQLite.

Target Website:

Tool:

  • Python
  • SQLite

Steps

  1. Go through the structure of website: When you inspect the website, you can see the information of case located in the tag of <tr>.

2. I am designing a pattern based on the regular expression to extract the key elements.

--

--

DigNo Ape
DigNo Ape

Written by DigNo Ape

我們秉持著從原人進化的精神,不斷追求智慧的累積和工具的運用來提升生產力。我們相信,每一個成員都擁有無限的潛力,透過學習和實踐,不斷成長和進步。

No responses yet