Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 9078195
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 16, 20262026-06-16T19:33:35+00:00 2026-06-16T19:33:35+00:00

While developing java apps that connects to database, it seems like we have two

  • 0

While developing java apps that connects to database, it seems like we have two options:

  • Use the standard java.sql classes
  • Use the vendor specific classes (like we have com.mysql.jdbc.Connection and we also have java.sql.Connection).

Which one is the recommended to use? Say I am currently using mysql. But in the future I might switch to oracle. Is there any performance bonus for using the vendor specific implementation?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-16T19:33:36+00:00Added an answer on June 16, 2026 at 7:33 pm

    In most cases, you won’t notice a performance difference.

    The java.sql package represents a most common denominator between different databases, while the vendor-specific packages also expose some features which are exclusive to the database backend. But when you want to keep the option open to switch the database backend later, you should avoid these anyway, because it is possible that the new database got no equivalent functionality and you need to solve the problem in a completely different way, which could in the end require some large-scale refactoring of your entire application.

    tl;dr: When you want to keep the option open to switch to Oracle or any other SQL database, use java.sql.

    Or even better: use an object-relational mapping framework like Hibernate to do the database abstraction for you. They need a while to get used to, but afterwards you will be able to implement database functionality with a lot less man-hours and switching the database backend will be a one-line change in a configuration file.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

We have a Java applet that needs to run with full trust. While developing
Am Beginner to java.I have a small doubt while i am developing an application
I've been playing around with developing Android apps in Java for a while and
I have been developing command line programs in Java for a while now and
While developing my Java EE application I've encountered two situations in which my entities
While Developing a Java EE Web app, I would like to know simple ways
I have been developing iOS apps for a while but they all deal with
While developing a Java project, I place all of my jar files in a
While developing my ASP.NET MVC, I have started to see the need for a
While developing my WordPress application i have a requirement where i need to show

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.