• 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
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

login problems

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

I could really use some help, I have a problem with my webapplication.
(I am using mysql for database server, and netbeans for coding and running the application)

the project can be downloaded here:

https://drive.google.com/file/d/0B2JQKtOcHtUgb1hZVW9oUkxWTzQ/view?usp=sharing

first.

i run the CreateRyanAir.sql file (contained in the examproject.rar) to generate the database.

after this i open the project and run it.

When i am running the project RyanAirExamProject the output is:



after this the application loads in chrome as it should, but however when i am logging in with the user i inserted in the database the application gives me :



I think something is wrong with the connection between mysql and netbeans, but i am far from sure.
I am desperate for solving the problem since exames are close!, i hope that someone could try running the project, and give a brother some help :|...

Good sunday,

link to download project

https://drive.google.com/file/d/0B2JQKtOcHtUgb1hZVW9oUkxWTzQ/view?usp=sharing

BR
Mikkel
mysql.PNG
[Thumbnail for mysql.PNG]
 
Mike dawn
Greenhorn
Posts: 9
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
What?
 
Marshal
Posts: 28177
95
Eclipse IDE Firefox Browser MySQL Database
  • Likes 1
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Here's the relevant entry from the stack trace:

Internal Exception: java.sql.SQLException: Access denied for user 'root'@'localhost' (using password: YES)



This means that you haven't correctly configured MySQL to accept requests from user "root" from the local host. So you should review the configuration and get that problem fixed. That's nothing to do with your code, by the way. You'll need to connect to the MySQL instance on your server as an administrator and authorize "root" to connect from localhost.

Actually it would be better to create a new MySQL user for this project and configure access for that user. Using the "root" profile for non-administrative tasks could be a security problem.
 
Mike dawn
Greenhorn
Posts: 9
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Paul Clapham wrote:Here's the relevant entry from the stack trace:

Internal Exception: java.sql.SQLException: Access denied for user 'root'@'localhost' (using password: YES)



This means that you haven't correctly configured MySQL to accept requests from user "root" from the local host. So you should review the configuration and get that problem fixed. That's nothing to do with your code, by the way. You'll need to connect to the MySQL instance on your server as an administrator and authorize "root" to connect from localhost.

Actually it would be better to create a new MySQL user for this project and configure access for that user. Using the "root" profile for non-administrative tasks could be a security problem.



Hi thanks for the answer, i made a new user in MySQL and gave it all privileges

trying to configure it between mysql and netbeans, but i think i am doing it wrong..

Screenshots of what i have done so far:

https://drive.google.com/folderview?id=0B2JQKtOcHtUgaE0zMGVJMVNfWWc&usp=sharing


i am confused, help please
 
Bartender
Posts: 3648
16
Android Mac OS X Firefox Browser Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Say you have created the new user, can you use this new user to log in to MySQL through netbeans or MySQL admin gui?

If so, that user is functioning as expected. Next is to configure the access in your project to use this new user.
 
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
reply
    Bookmark Topic Watch Topic
  • New Topic