mycat sub-database sub-table

Mycat is a good introductory article: http://blog.sina.com.cn/s/blog_499740cb0100ugs7.html

For me and our java programmers through mycat, in fact, mycat manages multiple databases into one database. We do not need to know the implementation of mycat, or operate a data to operate the logical database generated by mycat.

jdbc.username=root
jdbc.password=123456
jdbc.driver=com.mysql.jdbc.Driver
jdbc.url=jdbc:mysql://127.0.0.1:8066/TESTDB

The default port of mycat is 8066. TESTDB is the logical database name. username and password are the username and password of mycat, which can be seen in the blog above.

Java sub-library sub-table code:

Results of the:

Actual database effect:

Guess you like

Origin http://43.154.161.224:23101/article/api/json?id=325564808&siteId=291194637