============ Problem Description ============
On the server side, the query results are placed in the list by the following code, and the result is that there is no first row. Obviously with Beforefirst () moved to the first line, but still no effect. Excuse me, what's going on here?
Jdbconnection sqlconn = new Jdbconnection (); ResultSet resres = Sqlconn.executequery ("SELECT * from Message"), int row = 0;try {resres.last (); row = Resres.getrow (); ResultSetMetaData RESMD = Resres.getmetadata (); int columns = Resmd.getcolumncount (); Listall.clear (); Resres.beforefirst (); System.out.println (Resres.next ()), while (Resres.next ()) {for (int i = 1; I <= columns; i++) {System.out.println (resres . getString (i)); Listall.add (resres.getstring (i));}} catch (SQLException e) {//TODO auto-generated catch Blocke.printstacktrace ();}
============ Solution 1============
Drop the first line.
Android server-side query result issues