]> 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)
committerGitHub <noreply@github.com>
Wed, 12 Jul 2017 15:54:25 +0000 (11:54 -0400)
The Session class was used instead of the session instance which resulted in an attribute error.

doc/build/orm/tutorial.rst

index f742151b000a3800c32e7bab7372001c1171fd18..9569e4b1f9900b1684baa09f598f34671610a487 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: