]> git.ipfire.org Git - thirdparty/fastapi/sqlmodel.git/commitdiff
✏️ Fix typo in `cascade_delete` docs (#1030)
authorSebastián Ramírez <tiangolo@gmail.com>
Mon, 22 Jul 2024 22:52:55 +0000 (17:52 -0500)
committerGitHub <noreply@github.com>
Mon, 22 Jul 2024 22:52:55 +0000 (22:52 +0000)
docs/tutorial/relationship-attributes/cascade-delete-relationships.md

index 769d94cf9996d6494a8b2a83fbcda6b478d637ee..1604b9780b1c3b5a4f378ecb4aa412cb585dfe7b 100644 (file)
@@ -503,7 +503,7 @@ FROM team
 WHERE team.name = ?
 INFO Engine [generated in 0.00014s] ('Wakaland',)
 
-// Then, because of delete_cascade, right before deleting Wakaland, SQLAlchemy loads the heroes
+// Then, because of cascade_delete, right before deleting Wakaland, SQLAlchemy loads the heroes
 INFO Engine SELECT hero.id AS hero_id, hero.name AS hero_name, hero.secret_name AS hero_secret_name, hero.age AS hero_age, hero.team_id AS hero_team_id
 FROM hero
 WHERE ? = hero.team_id
@@ -531,7 +531,7 @@ Princess Sure-E not found: None
 
 We can configure the database to **set the foreign key** (the `team_id` in the `hero` table) to **`NULL`** when the related record (in the `team` table) is deleted.
 
-In this case, the side with `Relationship()` won't have `delete_cascade`, but the side with `Field()` and a `foreign_key` will have `ondelete="SET NULL"`.
+In this case, the side with `Relationship()` won't have `cascade_delete`, but the side with `Field()` and a `foreign_key` will have `ondelete="SET NULL"`.
 
 //// tab | Python 3.10+