Results 1 to 1 of 1
-
Calculating the DB connection time
The code sample below calculates the time it takes to connect to a database referred by dsn.
Java Code:long connection_time; Date start = new Date(); //get start time String stUrl_= "jdbc:odbc:myDSN"; connection_ = DriverManager.getConnection(stUrl,"sa","sa"); Date end = new java.util.Date(); //get end time connection_time = end.getTime()-start.getTime();
Similar Threads
-
Program for calculating area and hypotenus in a triangel
By Legoland in forum New To JavaReplies: 4Last Post: 08-12-2008, 01:41 PM -
Calculating trigonometric functions
By Java Tip in forum java.langReplies: 0Last Post: 04-16-2008, 10:56 PM -
Calculating hyperbolic functions
By Java Tip in forum java.langReplies: 0Last Post: 04-16-2008, 10:55 PM -
Calculating sin of a double value
By Java Tip in forum Java TipReplies: 0Last Post: 01-13-2008, 08:13 PM -
Hello, first time here.
By ludragon in forum IntroductionsReplies: 2Last Post: 01-03-2008, 05:03 AM


LinkBack URL
About LinkBacks
Reply With Quote
Bookmarks