Hibernate reverse engineering in Netbeans cannot find SQL Server tables

I have a SQL Server test database installed on my machine. I created a test account for SQL Server and two tables were created with this account in TestDb according to the default scheme. On my Java web application (simple JSP), I use Hibernate and configured it to point to a test database. However, when I create the hibernate.reveng file, the wizard does not find / display the available tables. See my hibernate configuration file:

<hibernate-configuration> <session-factory> <property name="hibernate.connection.driver_class">com.microsoft.sqlserver.jdbc.SQLServerDriver</property> <property name="hibernate.connection.url">jdbc:sqlserver://localhost:1433;databaseName=TestDb;</property> <property name="hibernate.connection.username">test</property> <property name="hibernate.connection.password">password</property> <property name="hibernate.dialect">org.hibernate.dialect.SQLServerDialect</property> </session-factory> </hibernate-configuration> 

There is no error in going to the step where I should see the tables. It just doesn't display anything in the two tables of the database tables. I can even save the xml file without any warnings / errors, but there is no table inside. I need help with the current installation, so I can display and map tables using the sleep wizard.

+4
source share
4 answers

Just add the MySql JDBC library file to the library, this worked for me.

+1
source

I have the same problem, I found this which explains how to get around the reverse engineering wizard. Its alternative near the end of the article is

http://netbeans.org/kb/docs/java/hibernate-java-se.html#10

0
source

Found out what the problem is. When you create a new entrance to the management studio, you can see in one of the parameters that the user uses. You must select this specific scheme when creating the sleep reversal file. I can post more information if anyone else has the same problems.

0
source

You should write

Integrated Security = true;

new hibernate.connection.url →

JDBC: SQLServer: // local: 1433; Databasename = TestDB Integrated Security = true;

0
source

All Articles