]> git.ipfire.org Git - thirdparty/sqlalchemy/sqlalchemy.git/commit
use only object_id() function for temp tables
authorMike Barry <michael.barry@gmo.com>
Wed, 26 Oct 2022 17:40:32 +0000 (13:40 -0400)
committermike bayer <mike_mp@zzzcomputing.com>
Fri, 28 Oct 2022 13:09:07 +0000 (13:09 +0000)
commit2ea71e5df9b662cd08b4c1581441449643fbe431
treee947ebab112b4912324e501fc0e0ee34baf56be7
parent6d77db96f72b72cf4797ad54eed2e3dc889aecf4
use only object_id() function for temp tables

Fixed issue with :meth:`.Inspector.has_table` when used against a temporary
table for the SQL Server dialect would fail an invalid object name error on
some Azure variants, due to an unnecessary information schema query that is
not supported on those server versions. Pull request courtesy Mike Barry.

the patch also fills out test support for has_table()
against temp tables, temp views, adding to the has_table() support just
added for views in #8700.

Fixes: #8714
Closes: #8716
Pull-request: https://github.com/sqlalchemy/sqlalchemy/pull/8716
Pull-request-sha: e2ac7a52e2b09a349a703ba1e1a2911f4d3c0912

Change-Id: Ia73e4e9e977a2d6b7e100abd2f81a8c8777dc9bb
(cherry picked from commit 2af33d79eddc696c0fb1ef749999fa5d0d33f214)
doc/build/changelog/unreleased_14/8700.rst
doc/build/changelog/unreleased_14/8714.rst [new file with mode: 0644]
lib/sqlalchemy/dialects/mssql/base.py
lib/sqlalchemy/testing/requirements.py
lib/sqlalchemy/testing/suite/test_reflection.py
test/requirements.py