Page 1 of 2 12 LastLast
Results 1 to 15 of 17
  1. #1
    Join Date
    Jul 2010
    Posts
    2

    Unanswered: DB2 Native driver vs Type4 driver

    Choice of appropriate drivers for connecting to DB2 database from BO Crystal Reports We have created Crystal reports by successfully connecting them to DB2 database using ODBC, JDBC(Type4 driver) and DB2 Unicode drivers.Which one out of the following three are we supposed to use so that we could get a better performance.
    which is better in performance DB2 Native driver or Type4 driver

  2. #2
    Join Date
    Jan 2009
    Location
    Zoetermeer, Holland
    Posts
    746
    You talk about Crystal Reports and type-4 drivers. I assume that Crystal Reports is a java-app?
    Is you application on the same server as the database?
    Then I would recommend the type-2 driver
    Else I would recommend the type-4 driver

  3. #3
    Join Date
    Aug 2008
    Location
    Toronto, Canada
    Posts
    2,367
    What is the difference between type-2 and type-4 drivers? How do you tell which one an application is using?
    Last edited by db2girl; 08-10-10 at 11:45.

  4. #4
    Join Date
    Jun 2003
    Location
    Toronto, Canada
    Posts
    5,516
    Provided Answers: 1
    Type 2 is what was formerly called the "app" driver, I think it works through CLI. Type 4 is Java-only, and it supports most of JDBC 3.0.

  5. #5
    Join Date
    Aug 2008
    Location
    Toronto, Canada
    Posts
    2,367
    How do you decide what to use with your application? How do I tell what the application is using, type 2 or type 4?

  6. #6
    Join Date
    Jun 2003
    Location
    Toronto, Canada
    Posts
    5,516
    Provided Answers: 1
    You use type 4 unless there is some reason why your application must use type 2 (which is deprecated anyway). The driver type is determined by the Java class name that you load, COM.ibm.db2.jdbc.app.DB2Driver (hence the "app" name) vs. com.ibm.db2.jcc.DB2Driver.

  7. #7
    Join Date
    Aug 2008
    Location
    Toronto, Canada
    Posts
    2,367
    How can a DBA determine the driver type their application is using without asking developers? Will some trace show com.ibm.db2.jdbc.app.DB2Driver or com.ibm.db2.jcc.DB2Driver? Or some other way?

  8. #8
    Join Date
    Jun 2003
    Location
    Toronto, Canada
    Posts
    5,516
    Provided Answers: 1
    I think the driver name shows in the application snapshot, at least for type 4.

  9. #9
    Join Date
    Aug 2008
    Location
    Toronto, Canada
    Posts
    2,367
    Do you know what to look for in the application snapshot? Application name or something else?

    I've seen db2jcc_application for the application name in the application snapshot / list applications. Does db2jcc_application indicate it's a type 4 driver?

  10. #10
    Join Date
    Jun 2003
    Location
    Toronto, Canada
    Posts
    5,516
    Provided Answers: 1
    Yes, I think it does.

  11. #11
    Join Date
    Aug 2010
    Posts
    1

    guy likes you

    If Crystal Reports is a java-app. What type of driver would you recommend? type-2 driver or type 4?

    guy likes you

  12. #12
    Join Date
    Jan 2009
    Location
    Zoetermeer, Holland
    Posts
    746
    Quote Originally Posted by db2girl View Post
    How can a DBA determine the driver type their application is using without asking developers? Will some trace show com.ibm.db2.jdbc.app.DB2Driver or com.ibm.db2.jcc.DB2Driver? Or some other way?
    Developers develop java-source containing JDBC-logic. Which jdbc-driver is used in production is mostly the choice of the DBA.

    I would always recommend the type-4 driver except when the application is on the same server as the database. In that case squeezing all the db-traffic through a tcp-ip socket (event if it is localhost) could become a bottleneck.

  13. #13
    Join Date
    Aug 2008
    Location
    Toronto, Canada
    Posts
    2,367
    Quote Originally Posted by dr_te_z View Post
    Which jdbc-driver is used in production is mostly the choice of the DBA.
    Do most DBAs really know enough about this in order to decide which one to use??

  14. #14
    Join Date
    Jun 2003
    Location
    Toronto, Canada
    Posts
    5,516
    Provided Answers: 1
    Quote Originally Posted by db2girl View Post
    Do most DBAs really know enough
    If they don't, I think they should.

  15. #15
    Join Date
    Aug 2008
    Location
    Toronto, Canada
    Posts
    2,367
    The more you know the better.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •