I want to count the total no of rows in a table
Class.forName("sun.jdbc.odbc.JdbcOdbcDriver");
Connection con = DriverManager.getConnection("jdbc:odbc:gabbar");
Statement ps1 = con.createStatement();
ResultSet count = ps1.executeQuery("SELECT COUNT (*) FROM products );
//products is a table in database
count is of ResultSet type.but i want to do arithmetic operation on count variable.i want count to be in int datatype.what should i do?
i dont know how to solve this problem