Win a copy of Functional Reactive Programming this week in the Other Languages forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Which set of SQL Classes do I use, JDBC, java.sql.* or javax.persistance?

 
Daniel Pride
Greenhorn
Posts: 11
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I am doing some java interactivity with a mysql database, mainly using Netbeans and beans binding. Most of the code is done for you but I'm going to be making applications which interact with a database independent of the binding process. I was wondering which set of Query, ResultSet, Statments etc I use, the ones provided by java.sql library or the ones that come with the JDBC (Connector/J in my case).
 
Paul Clapham
Sheriff
Posts: 21416
33
Eclipse IDE Firefox Browser MySQL Database
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You use the classes in the java.sql package, AND you use the classes in the Connector/J driver. But you use them in different ways. Rather than me trying to explain that, let me direct you to a document that already explains it in great detail:

JDBC Tutorial
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic