-->
These old forums are deprecated now and set to read-only. We are waiting for you on our new forums!
More modern, Discourse-based and with GitHub/Google/Twitter authentication built-in.

All times are UTC - 5 hours [ DST ]



Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 8 posts ] 
Author Message
 Post subject: Reverse Engineering does not create any output
PostPosted: Mon Jul 11, 2005 12:35 pm 
Newbie

Joined: Mon Jul 11, 2005 12:25 pm
Posts: 7
Location: Dublin, Ireland
I am using the hibernate tools version 4.0a. I am trying to connect to a SQL Server 2000 database. I can connect to the database no problem but when I run the reverse engineering tools to generate POJOs and Mapping files it produces no output, just a single file named GneralHbmSetting.hbm.xml that is empty.

Below is a copy of my configuration file:

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

I know that this issue has been raised by others in connection with oracle and the soluation was to make the username, password and default schema capital letters but that doesn't seem to work with SQL Server. Any help would be most appreciated.


Top
 Profile  
 
 Post subject:
PostPosted: Mon Jul 11, 2005 12:40 pm 
Hibernate Team
Hibernate Team

Joined: Tue Aug 26, 2003 6:10 am
Posts: 8615
Location: Neuchatel, Switzerland (Danish)
does your user have the proper rights to read the schema ?

_________________
Max
Don't forget to rate


Top
 Profile  
 
 Post subject:
PostPosted: Tue Jul 12, 2005 7:37 pm 
Newbie

Joined: Mon Jul 11, 2005 12:25 pm
Posts: 7
Location: Dublin, Ireland
Yeah, I user has access to everything in that schema. This is really stumping me. I used the hibernate tools on a MySQL database without any trouble but can't get it to work with SQL Server at all.


Top
 Profile  
 
 Post subject:
PostPosted: Tue Jul 12, 2005 9:31 pm 
Hibernate Team
Hibernate Team

Joined: Tue Aug 26, 2003 7:19 pm
Posts: 2364
Location: Brisbane, Australia
Use jTDS jdbc driver. Works like a charm.

In the past with the microsoft driver I have to include the schema and catalog as well to get it to work. Anyway, I only use jTDS now and how had no issues getting it to connect to MSSQL.


Top
 Profile  
 
 Post subject:
PostPosted: Thu Jul 14, 2005 10:25 am 
Newbie

Joined: Mon Jul 11, 2005 12:25 pm
Posts: 7
Location: Dublin, Ireland
That worked like a charm. David you are a lifesaver. I would have thought that Microsoft knew how to write a good JDBC driver for their own database but I guess not. jTDS is definitely the way to go.


Top
 Profile  
 
 Post subject:
PostPosted: Thu Jul 14, 2005 9:45 pm 
Hibernate Team
Hibernate Team

Joined: Tue Aug 26, 2003 7:19 pm
Posts: 2364
Location: Brisbane, Australia
Thanks - Microsoft JDBC has not been all that good in the past I understand they have a new release that is much improved - I would not bother. jTDS is a fine product and works very well.


Top
 Profile  
 
 Post subject:
PostPosted: Mon Jul 18, 2005 11:08 am 
jTDS Developer
jTDS Developer

Joined: Tue Feb 24, 2004 5:36 pm
Posts: 70
Location: Bucharest, Romania
David,

Actually the new Microsoft driver is an OEM-ed version of the JNetDirect driver so it should be much better than the old DataDirect derived one. However in my testing I found literally tens of bugs so they still have a long way to go (if they want to do it in the first place).

Alin,
The jTDS Project.


Top
 Profile  
 
 Post subject:
PostPosted: Mon Jul 18, 2005 8:48 pm 
Hibernate Team
Hibernate Team

Joined: Tue Aug 26, 2003 7:19 pm
Posts: 2364
Location: Brisbane, Australia
Thanks for the detailed clarification.


Top
 Profile  
 
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 8 posts ] 

All times are UTC - 5 hours [ DST ]


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
© Copyright 2014, Red Hat Inc. All rights reserved. JBoss and Hibernate are registered trademarks and servicemarks of Red Hat, Inc.