summaryrefslogtreecommitdiff
path: root/examples
diff options
context:
space:
mode:
authorFederico Caselli <cfederico87@gmail.com>2020-03-03 22:32:19 +0100
committerFederico Caselli <cfederico87@gmail.com>2020-03-03 21:33:49 +0000
commit41001d5358549f89b7a4843b3421742b7e3adf3e (patch)
treec78429416405a59f8a1ccc6a534e0030b2177d91 /examples
parent4c81d99bab0e884473abfcb573772aa5d94264c7 (diff)
downloadsqlalchemy-41001d5358549f89b7a4843b3421742b7e3adf3e.tar.gz
Remove the deprecated loader options
Remove the deprecated loader options ``joinedload_all``, ``subqueryload_all``, ``lazyload_all``, ``selectinload_all``. The normal version with method chaining should be used in their place. Fixes: #4642 Change-Id: I12eb4dfa7a86375911a570934ee662653d85d50a
Diffstat (limited to 'examples')
-rw-r--r--examples/adjacency_list/adjacency_list.py7
1 files changed, 5 insertions, 2 deletions
diff --git a/examples/adjacency_list/adjacency_list.py b/examples/adjacency_list/adjacency_list.py
index 8cdd88540..fee0f413f 100644
--- a/examples/adjacency_list/adjacency_list.py
+++ b/examples/adjacency_list/adjacency_list.py
@@ -5,7 +5,7 @@ from sqlalchemy import Integer
from sqlalchemy import String
from sqlalchemy.ext.declarative import declarative_base
from sqlalchemy.orm import backref
-from sqlalchemy.orm import joinedload_all
+from sqlalchemy.orm import joinedload
from sqlalchemy.orm import relationship
from sqlalchemy.orm import Session
from sqlalchemy.orm.collections import attribute_mapped_collection
@@ -108,7 +108,10 @@ if __name__ == "__main__":
node = (
session.query(TreeNode)
.options(
- joinedload_all("children", "children", "children", "children")
+ joinedload("children")
+ .joinedload("children")
+ .joinedload("children")
+ .joinedload("children")
)
.filter(TreeNode.name == "rootnode")
.first()