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.  [ 2 posts ] 
Author Message
 Post subject: Error while trying to login to database
PostPosted: Thu Apr 27, 2006 6:30 am 
Newbie

Joined: Thu Apr 27, 2006 5:49 am
Posts: 4
Hai all,
I am new to the hibernate world. I just wanted to try out a sample application using hibernate with postgresql database. I am trying this from the myeclipse IDE.
Here are the steps i am following

1. Created a new java project.
2. Add hibernate capabilities
a. Add Hibernate 2.1 libraries to the project.
b. Configuration File Path : /HiperDemo/src
c. Configuration File Name: hibernate.cfg.xml
d. Connection profile: postprofile
e. Database URL: jdbc:postgresql://localhost:5432/user
f. Driver class : org.postgresql.Driver
g. username:
h. password:
i. Hibernate Dialect : PostgreSQL

3. Session Factory class: com.Hibernate.SessionManager
Source Folder:/src

4. Now the project is created and i can see the Sesionmanager.java and
hibernate.cfg.xml files.
5. Now I had selected the MyEclipse Database explorer perspective and when i click open connection on the specific profile i am always getting the following error.

Error while trying to login to database: org.postgresql.Driver

I am not able to understand why i am getting this error. Even i tried it out with the mysql database and i got the following errror.

Error while trying to login to database: com.mysql.jdbc.Driver

Please help me out in soving this problem.

_________________
Regards,
Jaya kumar


Top
 Profile  
 
 Post subject: Re: Error while trying to login to database
PostPosted: Thu Apr 27, 2006 6:36 am 
Senior
Senior

Joined: Mon Aug 22, 2005 5:45 am
Posts: 146
jayakumar wrote:
Hai all,
I am new to the hibernate world. I just wanted to try out a sample application using hibernate with postgresql database. I am trying this from the myeclipse IDE.
Here are the steps i am following

1. Created a new java project.
2. Add hibernate capabilities
a. Add Hibernate 2.1 libraries to the project.
b. Configuration File Path : /HiperDemo/src
c. Configuration File Name: hibernate.cfg.xml
d. Connection profile: postprofile
e. Database URL: jdbc:postgresql://localhost:5432/user
f. Driver class : org.postgresql.Driver
g. username:
h. password:
i. Hibernate Dialect : PostgreSQL

3. Session Factory class: com.Hibernate.SessionManager
Source Folder:/src

4. Now the project is created and i can see the Sesionmanager.java and
hibernate.cfg.xml files.
5. Now I had selected the MyEclipse Database explorer perspective and when i click open connection on the specific profile i am always getting the following error.

Error while trying to login to database: org.postgresql.Driver

I am not able to understand why i am getting this error. Even i tried it out with the mysql database and i got the following errror.

Error while trying to login to database: com.mysql.jdbc.Driver

Please help me out in soving this problem.


this problem is in no way related to hibernate.
it's an issue of myeclipseide.
you need to add the JDBC-drivers to your projects build-path and it will work.

_________________
Please don't forget to give credit, if my posting helped to solve your problem.


Top
 Profile  
 
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 2 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.