bug fix: missing table (sql)

v2.4
Steve Nyemba 1 month ago
parent c7a5d42f42
commit b1975d6a42

@ -1,6 +1,6 @@
__app_name__ = 'data-transport'
__author__ = 'The Phi Technology'
__version__= '2.4.20'
__version__= '2.4.22'
__edition__= 'enterprise'
__email__ = "info@the-phi.com"
__license__=f"""

@ -56,13 +56,18 @@ class Base:
# _map = {'BIGINT':'INTEGER','TEXT':'STRING','DOUBLE_PRECISION':'FLOAT','NUMERIC':'FLOAT','DECIMAL':'FLOAT','REAL':'FLOAT'}
# _schema = [{"name":_attr.name,"type":_map.get(str(_attr.type),str(_attr.type))} for _attr in _handler.tables[_table].columns]
#
try:
if _table :
_inspector = inspect(self._engine)
_columns = _inspector.get_columns(_table)
_schema = [{'name':column['name'],'type':_map.get(str(column['type']),str(column['type'])) } for column in _columns]
return _schema
else:
except Exception as e:
pass
# else:
return []
def has(self,**_args):
return self.meta(**_args)
def apply(self,sql):

Loading…
Cancel
Save