I don't want a new search. I have a Jtable to display the ResultSet and I 
want to know what is the row to jump with the desired value.
Thanks.

>>>>>>>>>>>>>>>>>> Notizia originaria <<<<<<<<<<<<<<<<<<

Il 17/03/2003, 19.56.34, =?windows-1252?Q?Sven_K=F6hler?= <[EMAIL PROTECTED]> 
ha scritto sull�argomento Re search inside a ResultSet:


> > I have this question:
> > if in a Java program I have a fragment of code like the following:
> > --------------
> > String sql = "SELECT People.firstName, People.lastName FROM People order
> > by lastName";
> > PreparedStatement pst = conn.prepareStatement(sql);
> > ResultSet rs = pst.executeQuery();
> > how can I search a value int it without scanning all records in the
> > resultSet with a �while(rs.next())�? I would search, for example, the
> > lastName �Berry�.

> In ADODB you had something like
>    rs.Filter="People.lastName='Berry'"
> but this was simply "merged" with the previous query, and in your case
> this generates
>    SELECT People.firstName, People.lastName FROM People WHERE
> People.lastName='Berry' ORDER BY lastName

> so just execute another query again.


> _______________________________________________
> sapdb.general mailing list
> [EMAIL PROTECTED]
> http://listserv.sap.com/mailman/listinfo/sapdb.general

_______________________________________________
sapdb.general mailing list
[EMAIL PROTECTED]
http://listserv.sap.com/mailman/listinfo/sapdb.general

Reply via email to