Files
sqlalchemy/test/sql
OSS Contributor f862a4534a Fix floordiv (//) for float/numeric by int with div_is_floordiv dialects
Fixed issue where floor division (``//``) between a :class:`.Float` or
:class:`.Numeric` numerator and an :class:`.Integer` denominator would omit
the ``FLOOR()`` SQL wrapper on dialects where
:attr:`.Dialect.div_is_floordiv` is ``True`` (the default, including
PostgreSQL and SQLite).  ``FLOOR()`` is now applied if either the
denominator or the numerator is a non-integer, so that expressions such as
``float_col // int_col`` render as ``FLOOR(float_col / int_col)`` instead
of the incorrect ``float_col / int_col``.  Pull request courtesy r266-tech.

Fixes: #10528

Closes: #13191
Pull-request: https://github.com/sqlalchemy/sqlalchemy/pull/13191
Pull-request-sha: c9cbc47c87

Change-Id: I5f9f02d966aa6ccee214a2c5cc27a73a4292da03
2026-05-20 15:25:53 -04:00
..
2025-11-30 14:38:13 -05:00
2026-05-10 19:00:42 +02:00
2025-12-18 21:18:42 +01:00
2026-05-10 19:00:42 +02:00
2025-12-19 21:24:23 +01:00
2026-05-10 19:00:42 +02:00
2025-11-30 14:38:13 -05:00