This week's book giveaway is in the Clojure forum.
We're giving away four copies of Clojure in Action and have Amit Rathore and Francis Avila on-line!
See this thread for details.
Win a copy of Clojure in Action this week in the Clojure forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

NetBeans and Database pools

 
Mike Tabak
Ranch Hand
Posts: 70
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I'm working with a NetBeans project which has a servlet that accesses the MySQL database using a connection pool. With the code completed the name of the project is red indicating a problem. When I right click on the project name at the bottom I see "Resolve data source problem". When I click on that I get a Resolve Data Sources pop-up. I fill in the appropriate info and close it, but the project name remains red and when I right click on it I get the same error about data sources. However, when I deploy to Tomcat everything works perfectly. Any ideas why the project name remains red with the same error? (there are no red indications on any of the packages). I am using NetBeans 7.1.2.

Thanks
Mike
 
Peter Johnson
author
Bartender
Posts: 5852
7
Android Eclipse IDE Ubuntu
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
This is just a guess, but could it be that NetBeans needs the MySQL JDBC driver to be registered to verify the database URL?
 
Mike Tabak
Ranch Hand
Posts: 70
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
The driver info id in the WEB-INF/context.xml, doesn't this register it? Would the program still work with an unregitered driver?

Thanks
Mike
 
Peter Johnson
author
Bartender
Posts: 5852
7
Android Eclipse IDE Ubuntu
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
No, that would not register it. The JAR file for the driver must be registered with NetBeans, probably by including the driver JAR in the list of JARs for the project.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic