--- "Paananen, Tero" <[EMAIL PROTECTED]> wrote: > > Some databases let you specify a LIMIT clause, which limits > > the results > > to whatever you specify, and an OFFSET clause, which starts > > the results > > at the indicated offset. Using these you can achieve an > > elegant subset > > of results based on start and end position (and it is IMHO > > the best way > > to implement the kind of feature you're describing). > > The disadvantage of this approach is that you'll be > tieing your implementation to a specific db vendor > at that point.
Not if you store the SQL in a properties file. > DB vendors implement such functionality > differently, from what I've seen. If you just need to limit the number of rows, you can call Statement.setMaxRows(int). David > > I've yet to see an application that does NOT target a > specific db though. YMMV. > > -TPP > > ----------------------------------------- > This email may contain confidential and privileged material for the sole > use of the intended recipient(s). Any review, use, retention, > distribution or disclosure by others is strictly prohibited. If you are > not the intended recipient (or authorized to receive for the recipient), > please contact the sender by reply email and delete all copies of this > message. Also, email is susceptible to data corruption, interception, > tampering, unauthorized amendment and viruses. We only send and receive > emails on the basis that we are not liable for any such corruption, > interception, tampering, amendment or viruses or any consequence > thereof. > > > --------------------------------------------------------------------- > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > __________________________________ Do you Yahoo!? Yahoo! SiteBuilder - Free, easy-to-use web site design software http://sitebuilder.yahoo.com --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]