From: Mike Bayer Date: Mon, 18 Sep 2023 20:43:31 +0000 (-0400) Subject: doc fixes X-Git-Tag: rel_2_0_21~2 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=b6510069181230e30741c54a1489bfd99c49d3eb;p=thirdparty%2Fsqlalchemy%2Fsqlalchemy.git doc fixes Change-Id: I97f4985ccfcaaa6da75ff89defe0dd62c61d0559 --- diff --git a/doc/build/changelog/unreleased_20/10279.rst b/doc/build/changelog/unreleased_20/10279.rst index 4a851cbdd2..f7d29a36bd 100644 --- a/doc/build/changelog/unreleased_20/10279.rst +++ b/doc/build/changelog/unreleased_20/10279.rst @@ -2,9 +2,11 @@ :tags: bug, orm :tickets: 10279 - Adjusted the ORM's interpretation of UPDATE/DELETE targets to not interfere - with the target table passed to the statement, such as for - :class:`_orm.aliased` constructs. Cases like ORM session synchonize using - "SELECT" statements such as with MySQL/ MariaDB will still have issues with + Adjusted the ORM's interpretation of the "target" entity used within + :class:`.Update` and :class:`.Delete` to not interfere with the target + "from" object passed to the statement, such as when passing an ORM-mapped + :class:`_orm.aliased` construct that should be maintained within a phrase + like "UPDATE FROM". Cases like ORM session synchonize using "SELECT" + statements such as with MySQL/ MariaDB will still have issues with UPDATE/DELETE of this form so it's best to disable synchonize_session when using DML statements of this type. diff --git a/doc/build/orm/queryguide/inheritance.rst b/doc/build/orm/queryguide/inheritance.rst index 0cb44b8ac7..98fac2bc97 100644 --- a/doc/build/orm/queryguide/inheritance.rst +++ b/doc/build/orm/queryguide/inheritance.rst @@ -299,17 +299,17 @@ Applying loader options when selectin_polymorphic is itself a sub-option .. versionadded:: 2.0.21 -The previous section illustrated -:func:`_orm.selectin_polymorphic` and :func:`_orm.selectinload` used as siblings -within a call to :func:`_sql.select.options`. If the target entity is one that -is already being loaded from a parent relationship, as in the example at +The previous section illustrated :func:`_orm.selectin_polymorphic` and +:func:`_orm.selectinload` used as sibling options, both used within a single +call to :meth:`_sql.select.options`. If the target entity is one that is +already being loaded from a parent relationship, as in the example at :ref:`polymorphic_selectin_as_loader_option_target`, we can apply this "sibling" pattern using the :meth:`_orm.Load.options` method that applies sub-options to a parent, as illustrated at -:ref:`orm_queryguide_relationship_sub_options`. Below we combine the two examples -to load `Company.employees`, also loading the attributes for the `Manager` and -`Engineer` classes, as well as eagerly loading the `Manager.paperwork` -attribute:: +:ref:`orm_queryguide_relationship_sub_options`. Below we combine the two +examples to load ``Company.employees``, also loading the attributes for the +``Manager`` and ``Engineer`` classes, as well as eagerly loading the +```Manager.paperwork``` attribute:: >>> from sqlalchemy.orm import selectinload >>> stmt = select(Company).options(