]> git.ipfire.org Git - thirdparty/sqlalchemy/sqlalchemy.git/commitdiff
updated doc string to show `NOT (EXISTS` instead of `NOT EXISTS`, as …
authorjonathan vanasco <jonathan@2xlp.com>
Sat, 14 Mar 2020 12:27:43 +0000 (08:27 -0400)
committersqla-tester <sqla-tester@sqlalchemy.org>
Sat, 14 Mar 2020 12:27:43 +0000 (08:27 -0400)
…that is what SqlAlchemy now renders.

SqlAlchemy currently renders `NOT (EXISTS` not `NOT EXISTS`. This fixes the example SQL.

### Description
The change is a docstring only.

### Checklist

This pull request is:

- [x] A documentation / typographical error fix
- Good to go, no issue or tests are needed
- [ ] A short code fix
- please include the issue number, and create an issue if none exists, which
  must include a complete example of the issue.  one line code fixes without an
  issue and demonstration will not be accepted.
- Please include: `Fixes: #<issue number>` in the commit message
- please include tests.   one line code fixes without tests will not be accepted.
- [ ] A new feature implementation
- please include the issue number, and create an issue if none exists, which must
  include a complete example of how the feature would look.
- Please include: `Fixes: #<issue number>` in the commit message
- please include tests.

**Have a nice day!**

Closes: #4593
Pull-request: https://github.com/sqlalchemy/sqlalchemy/pull/4593
Pull-request-sha: fef577313242a1f79feb18969118a8fbb93bb6e9

Change-Id: Iee826a1754d76c93c014b44374e0f9aeabb8d0b6

lib/sqlalchemy/orm/relationships.py

index f8437a00ffc36ca0cff8140a2bffd5679d20378b..227543485f63b39dcc4bdb0ab473b537125c42d0 100644 (file)
@@ -1285,8 +1285,8 @@ class RelationshipProperty(StrategizedProperty):
             will produce::
 
                 SELECT * FROM my_table WHERE
-                NOT EXISTS (SELECT 1 FROM related WHERE
-                related.my_id=my_table.id)
+                NOT (EXISTS (SELECT 1 FROM related WHERE
+                related.my_id=my_table.id))
 
             :meth:`~.RelationshipProperty.Comparator.any` is only
             valid for collections, i.e. a :func:`.relationship`