aspose file tools*
The moose likes Java in General and the fly likes jdbc question Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Spring in Action this week in the Spring forum!
JavaRanch » Java Forums » Java » Java in General
Bookmark "jdbc question" Watch "jdbc question" New topic
Author

jdbc question

Deolu Lanipekun
Greenhorn

Joined: Mar 31, 2003
Posts: 1
Greetings everyone.
What is the difference between jdbc and odbc and the advantages of each.
Also what is the difference between 3tier and 2nd tier model?
Any useful answer would be appreciated
Rufus BugleWeed
Ranch Hand

Joined: Feb 22, 2002
Posts: 1551
JDBC and ODBC are sort of competitors. ODBC is Microsofts API for accessing data in an RDBMS. By changeing drivers one could port a program from MySQL to Oracle. The program does not have to change because it uses a standard API to access the database.
JDBC is a similar technology in JavaLand.
In a two tier architecture the application program that makes access directly to the database and publishes an output.
In a three tier architecture some middleware ( classes objects ) provide a buffer between the database and the client. Suppose you had a database tables of customers, phone numbers, and addresses. A given client might need data out of these three tables for an address book like presentation.
Now an application client ( SWING ) might fetch all this data itself. A second web client could fetch it all too. Now if there is a change in the database where the customer table gets split into two tables both clients have to be re-worked.
If the database is hidden behind a class and the customer table gets split then maybe only the class the supports both the web client and the application client will need to be modifed.
Its gets easier if both clients use a common class to validate addresses rather than each having their own private routines.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: jdbc question