因为mysql数据库使用Schema作为数据库名称而不是目录
because mysql use Schema for database name not catalog
flowable查询表的源码:
tables = databaseMetaData.getTables(catalog, schema, tableName, JDBC_METADATA_TABLE_TYPES);
可以在url中增加&nullCatalogMeansCurrent=true参数,具体源码如下:
public java.sql.ResultSet getTables(String catalog, String schemaPattern, String tableNamePattern, final String[] types) throws SQLException {
final SortedMap<TableMetaDataKey, Row> sortedRows = new TreeMap<>();
final ArrayList<Row> tuples = new ArrayList<>();
final Statement stmt = this.conn.getMetadataSafeStatement();
if (catalog == null && this.nullCatalogMeansCurrent) {
catalog = this.database;
}