summaryrefslogtreecommitdiff
path: root/lib/sqlalchemy/sql/compiler.py
diff options
context:
space:
mode:
authorMike Bayer <mike_mp@zzzcomputing.com>2019-10-17 21:29:51 -0400
committerMike Bayer <mike_mp@zzzcomputing.com>2019-10-17 22:13:45 -0400
commitadd9cdd6628f7663229c5e549afac7041a06cfd9 (patch)
tree59b1f08fc7b18d525af39d45e7d2de6c2ecf1033 /lib/sqlalchemy/sql/compiler.py
parentd25c03310fd3523392d37b88c23c48cf26836248 (diff)
downloadsqlalchemy-add9cdd6628f7663229c5e549afac7041a06cfd9.tar.gz
Ensure SQL Server default schema name not interpreted as dot-separated tokens
Fixed an issue in the :meth:`.Engine.table_names` method where it would feed the dialect's default schema name back into the dialect level table function, which in the case of SQL Server would interpret it as a dot-tokenized schema name as viewed by the mssql dialect, which would cause the method to fail in the case where the database username actually had a dot inside of it. In 1.3, this method is still used by the :meth:`.MetaData.reflect` function so is a prominent codepath. In 1.4, which is the current master development branch, this issue doesn't exist, both because :meth:`.MetaData.reflect` isn't using this method nor does the method pass the default schema name explicitly. The fix nonetheless guards against the default server name value returned by the dialect from being interpreted as dot-tokenized name under any circumstances by wrapping it in quoted_name(). Fixes: #4923 Change-Id: I821bd38ed89b767eaca0bdffee7f8ba3baf82560
Diffstat (limited to 'lib/sqlalchemy/sql/compiler.py')
0 files changed, 0 insertions, 0 deletions