Win a copy of TDD for a Shopping Website LiveProject this week in the Testing forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Paul Clapham
  • Ron McLeod
  • Jeanne Boyarsky
  • Tim Cooke
Sheriffs:
  • Liutauras Vilda
  • paul wheaton
  • Henry Wong
Saloon Keepers:
  • Tim Moores
  • Tim Holloway
  • Stephan van Hulst
  • Carey Brown
  • Frits Walraven
Bartenders:
  • Piet Souris
  • Himai Minh

MySQL, Maven, Hibernate, MacOSX - Authentication

 
Greenhorn
Posts: 1
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi,

I'm trying to get a project working with the above. When I run the hibernate3:hbm2cfgxml goal, I get two stack traces:
The topline of the first is:
'org.hibernate.exception.GenericJDBCException: Getting database metadata'

The topline of the second is:
'Caused by: java.sql.SQLException: Access denied for user 'rogergraham'@'localhost' (using password: YES)'

I do not understand what to put for hibernate.connection.username and hibernate.connection.password.

I have to sudo to run mysql (where it runs as root: yes I know this is bad, but I'm just starting with the Mac so please be forgiving!) But even if I put the root username/password combination in, I get the same error.

Is there something I'm missing here? When you have a JDBC connection and supply the username/password, this is the combination that is set on the database instance itself, right? I'm very confused...

Any help greatly appreciated!


Thanks,
Roger
 
author & internet detective
Posts: 41073
848
Eclipse IDE VI Editor Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Roger,
Welcome to JavaRanch!

We have a special forum for ORM. Since this is about Hibernate and not pure JDBC, I'm moving it there. This question does pertain to a bunch of technologies though. If the conversation shifts back to JDBC (or Maven) someone can move it again. For now, I think you will get the most help in the ORM forum.
 
Ranch Hand
Posts: 49
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi,

This is problem of the system authentication... if your system has got the
admin privileges then use this ..........there is no code problem.......

You can also use

rogergraham@IPADDresss (like 192.168.100.13)(then also it will not work)


privileges.............prblm....
 
Ranch Hand
Posts: 364
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Quite likely a MySQL authorization issue. Try with standalone MySQL.
 
Can't .... do .... plaid .... So I did this tiny ad instead:
free, earth-friendly heat - a kickstarter for putting coin in your pocket while saving the earth
https://coderanch.com/t/751654/free-earth-friendly-heat-kickstarter
reply
    Bookmark Topic Watch Topic
  • New Topic