数据库逆向工程(DBRE)加载项。架构不存在或没有任何表

时间:2014-10-03 02:40:15

标签: spring spring-mvc spring-roo

我尝试使用Roo数据库逆向工程(DBRE)加载项还原我的MYSQL数据库。当我使用命令

对数据库进行内省时
 database introspect --schema demohibernate

我收到错误

Schema(s) 'demohibernate' do not exist or does not have any tables. Note that the schema names of some databases are case-sensitive

我检查了架构(数据库)demohibernate存在于我的数据库中。我通过roo命令检查项目的数据库配置

database properties list

我得到了结果

database properties list
database.driverClassName = com.mysql.jdbc.Driver
database.password = 123456
database.url = jdbc:mysql://localhost:3306
database.username = root

用户名和密码是正确的。我安装了MYSQL数据库的驱动程序。我不知道如何解决它。感谢您的帮助。

1 个答案:

答案 0 :(得分:4)

注意MySQL不使用模式,因此您的命令必须是:

roo> database introspect --schema no-schema-required 

此外,目标数据库名称必须包含在JDBC URL连接字符串中:

roo> database properties list
database.driverClassName = com.mysql.jdbc.Driver
database.password = 123456
database.url = jdbc:mysql://localhost:3306/demohibernate
database.username = root
相关问题