4 ms·
As someone who's used both SQL and Django ORM, I could ask: "Why SQL is so backward?" Here's a datapoint I experienced: The company I worked for didn't trust
by bb88 7y ago
As someone who's used both SQL and Django ORM, I could ask: "Why SQL is so backward?"
Here's a datapoint I experienced:
The company I worked for didn't trust the Django ORM for DB migrations. They thought they could do it by hand. After lots of deployment failures where the migration script worked in the dev environment but failed in the prod environment, we switched to using django migrations. Haven't had an issue since.
The author even admits that migrations are a hard problem, but yet, he has no solutions other than just using raw SQL.
Edited to Add:
In Django, these migrations are handled pretty well with a single command to make the migrations. In SQL, someone would probably have to spend some time testing, and then would need to be reviewed in the PR.
- rectangletangle 7y agoIn my experience Django's migrations are really solid, assuming you're using the PG or Sqlite backends. This is especially true if you're working from a new Django project, and not a "legacy system" that wasn't initially built for Django.