Skip to content

Commit

Permalink
fixed bug when table not in lowercase
Browse files Browse the repository at this point in the history
  • Loading branch information
daimor committed May 24, 2023
1 parent 0f28f7e commit 15ac98b
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions sqlalchemy_iris/base.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@
from sqlalchemy.sql import func
from sqlalchemy.sql.functions import ReturnTypeFromArgs
from sqlalchemy.sql.elements import Null
from sqlalchemy.sql.elements import quoted_name
from sqlalchemy.sql import expression
from sqlalchemy.sql import schema
from sqlalchemy import sql, text
Expand Down Expand Up @@ -1676,3 +1677,8 @@ def get_view_definition(self, connection, view_name, schema=None, **kw):
if view_def:
return view_def
raise exc.NoSuchTableError(f"{schema}.{view_name}")

def normalize_name(self, name):
if self.identifier_preparer._requires_quotes(name):
return quoted_name(name, quote=True)
return name

0 comments on commit 15ac98b

Please sign in to comment.