I have an assignment to use Java and C with MySQL database and compare the results and give reasons as to why such result.
No. of Records Execution time (ms) Records Java C 100 586 76 500 628 216 2000 733 697 5000 963 1056 10000 1469 2178
As you can see, with less number of records being fetched from the database, C(ODBC) performed better. But as the number of records were increased, Java(JDBC) came out as the winner.
The reason that I thought of is that may be the ODBC drivers load much faster than JDBC but the access speed of JDBC is better than ODBC, hence, such results. However, I am not able to find such reasoning anywhere.
Any suggestions please ?
Statements presented by mathworks website, these appear to be generally applicable.