是不是sql语句的问题
String sql2="select * from treeview where id="+id;
换成
String sql2="select * from treeview where id=" + "'" + id + "'";