]> git.ipfire.org Git - thirdparty/sqlalchemy/sqlalchemy.git/commitdiff
Replace Session class with session instance
authorTom Sitter <thomas.sitter@gmail.com>
Wed, 12 Jul 2017 15:54:25 +0000 (11:54 -0400)
committerMike Bayer <mike_mp@zzzcomputing.com>
Mon, 17 Jul 2017 14:31:45 +0000 (10:31 -0400)
The Session class was used instead of the session instance which resulted in an attribute error.
(cherry picked from commit 43f41fbfaa8f3030148c131628c5e9fe8fda9f66)

doc/build/orm/tutorial.rst

index 1deaf094507047e16662008570aae094d6ab1d0f..f089b650f44be14e11bd5e6e81eb8f171fa9632c 100644 (file)
@@ -1386,7 +1386,7 @@ is an important method at the center of usage for any SQL-fluent application.
     ON clause is a plain SQL expression.  To control the first entity in the list
     of JOINs, use the :meth:`.Query.select_from` method::
 
-        query = Session.query(User, Address).select_from(Address).join(User)
+        query = session.query(User, Address).select_from(Address).join(User)
 
 
 .. _ormtutorial_aliases: