Answer the question
In order to leave comments, you need to log in
Migration support or non-relational database?
An application based on PyQt5 and SQLite was written. The essence of the application: a simple database with a graphical interface. Allows you to add, modify, delete records within a specific, predefined, immutable model. The essence of my desire is as follows: I want to change the model, add fields to the tables. It is clear that this requires support for migrations. I first thought about using the SQLAlchemy ORM instead of PyQt's built-in ORM.
Fortunately, there is a PyQt binding to SQLAlchemy , and there is also such a utility for migrations to SQLAlchemy, judging by the reviews, it’s not bad.
What stops me: the vaunted complexity of SQLAlchemy. I'm not sure that for an application of 2500 lines it is rational to study this monster.
Tonight I accidentally stumbled upon such a thing as mongoDB. Apparently, a non-relational database can help me, especially since data can be transferred .
So the question is: in your experience, which approach would be more rational? Change ORM to SQLAlchemy or change database from SQLite to mongoDB?
Answer the question
In order to leave comments, you need to log in
It is impossible to answer you exactly, because. You have described the problem very vaguely.
1. Who is changing the data model? Are you as a developer releasing a new version of the application, or can the user do it too?
2. What kind of data is stored in tables? Are they relational in nature or not?
In general, the need to change the schema should not dictate which data model (and therefore DBMS) to use. In most projects using a relational database, the schema changes sooner or later, but no one moves to a document model just because they need to migrate data and schema.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question