#foreignkey β Public Fediverse posts
Live and recent posts from across the Fediverse tagged #foreignkey, aggregated by home.social.
-
One DELETE Cascades To 3.5 MILLION Rows?!
PRODUCTION APOCALYPSE! Deleted ONE user and CASCADE deleted 3.5 MILLION rows across 4 tables! Orders, payments, everything GONE! This is the scariest SQL behavior! Watch this nightmare!
#sql #sqldisaster #cascadedelete #foreignkey #productionbug #dataloss #sqlfails #massdeletion #sqlshorts #databasedisaster #sqlwtf #cascadenightmare
-
# #dt260208
# #sql
# #primarykey
# #foreignkey
# #SQLiteI had chatgpt refactor the bookbiz database schema (from PracticalSQL book 2nd ed). It added primary and foreign keys. I then had it refactor for SQLite specifically.
https://chatgpt.com/share/69894b9c-b944-8008-b758-b283987b4086
...
Highlights:
1. SQLite-Idiomatic Schema (Clean Rewrite)
Global settings (critical in SQLite)
PRAGMA foreign_keys = ON;
PRAGMA journal_mode = WAL;
PRAGMA synchronous = NORMAL; -
Django 5.0 has been released π
After months of work, everyone can use this great new version π
My favorite features are:
β’ π€ generated fields
β’ β database default values
β’ π prefetch related for generic foreign keysWhich are your favorite features?
https://www.djangoproject.com/weblog/2023/dec/04/django-50-released/#Django #GeneratedField #GeneratedColumn #Database #ORM #SQLite #PostgreSQL #MySQL #MariaDB #Default #ForeignKey #Django5 #Python #Python312 #Web #Framework #Release #ORM