Skip to content

Webscraping of the UOL website to obtain Brasileirão scores and load them into a MySQL database.

License

Notifications You must be signed in to change notification settings

welderessutti/webscraping_brasileirao_scores

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

10 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Webscraping Brasileirão Scores stored into MySQL Database

Webscraping

This is a webscraping script of the UOL website to obtain Brasileirão scores and load them into a MySQL database.

This script uses Python libraries like Selenium, BS4, Pandas, Numpy, JSON, Datetime and MySQL Connector.

It sends a request to UOL website, which has a Brasileirão scores table on the page. It gets website HTML content and scraps the data of the teams from the table, appending all of them into some lists.

Using the Pandas Lib, it´s created a dataframe and the lists are converted into a dictionary.

At last, the dictionary is converted into a JSON file and saved in the directory.

Storing into MySQL

In another script file, using the MySQL Connector lib, it´s created a connection and the cursor.

After, it´s created automatically a database named of "brasileirao", a table with the same name of the JSON file and its columns.

At last, the JSON file is opened and all of its dataset is inserted into the database table.

*Unfortunately, the application has been broken by updating some library. I'm still going to fix this.

About

Webscraping of the UOL website to obtain Brasileirão scores and load them into a MySQL database.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages