gtossou / appscraper

0 stars 0 forks source link

Cache google play data in db tables #2

Closed bbelderbos closed 2 years ago

bbelderbos commented 2 years ago

As discussed 1-to-many

-- to - many: Metrics (focus on first) -- to - many: Comments (focus on later)

Data as scraped here: https://github.com/gtossou/appscraper/issues/1

Can use SQLAlchemy but SQLModel is a nice abstraction that uses pydantic = type hints, better docs too: https://sqlmodel.tiangolo.com

bbelderbos commented 2 years ago

Let's already account for multiple stores, so the store would be an enumeration (android, apple for now) on the app table.

bbelderbos commented 2 years ago

Relations can be a bit tricky but they are explained well here: https://sqlmodel.tiangolo.com/tutorial/relationship-attributes/define-relationships-attributes/

bbelderbos commented 2 years ago

The 1-to-many app <> metrics is because the app will have various metrics associated over time, so the metrics rows should have a date when the data was taken and a column per metric, makes sense? That would be my take, open to any suggestions though.

bbelderbos commented 2 years ago

Great work, this is done