Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

多数据库 engine = get_connection(engine_name='default') 有问题 #71

Open
tangjn opened this issue Sep 2, 2016 · 1 comment
Open

Comments

@tangjn
Copy link

tangjn commented Sep 2, 2016

参考文档:http://limodou.github.io/uliweb-doc/zh_CN/db/multidb.html

比如想要获得 default 的连接对象:
engine = engine_manager['default'].engine \ 成功
或者直接使用 get_connection
engine = get_connection(engine_name='defa1111wwwwult') \ engine_name改成随便什么值都是取到default的连接

@limodou
Copy link
Owner

limodou commented Sep 3, 2018

例子可以看uliweb/test/test_multidb,测试代码在test/test_multidb.py

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants