feat: 添加未实现sqlSession方法

master
old-tom 2 years ago
parent 82d2b2c3d4
commit 3adc9ebfdf

@ -54,7 +54,7 @@ class DatabaseEngine(object):
'postgresql': 'postgresql+psycopg2://{0}:{1}@{2}:{3}/{4}', 'postgresql': 'postgresql+psycopg2://{0}:{1}@{2}:{3}/{4}',
'oracle': 'oracle+cx_oracle://{0}:{1}@{2}:{3}/?service_name={4}' 'oracle': 'oracle+cx_oracle://{0}:{1}@{2}:{3}/?service_name={4}'
} }
# 连接池容器名称,具体看ObjContainer对象
attr = 'engines' attr = 'engines'
def __init__(self, db_name, conf_path=DEFAULT_CONF_PATH): def __init__(self, db_name, conf_path=DEFAULT_CONF_PATH):

@ -91,6 +91,12 @@ class Sqlsession(object):
def insert(self, sql): def insert(self, sql):
return self.executor.execute_update(sql) return self.executor.execute_update(sql)
def insert_batch(self, sql):
"""
todo implement
"""
pass
def update(self, sql): def update(self, sql):
return self.executor.execute_update(sql) return self.executor.execute_update(sql)

Loading…
Cancel
Save