I wrote following the java program
import java.io.*; import java.util.*; import java.sql.Connection; import java.sql.DriverManager; import java.sql.ResultSet
Just use the jar command to extract the files your application needs to make the connection with the database server. e.g. jar -xf jdbc_file. Compile it with the javac -cp . and run it with the java -cp .
And that's it. It will work.