Wouldn't using ResultSet#previous() accomplish the same thing as a READP?
Not if you go before the first record in the result set. With a logical
file, you can position by key and then do a read previous.
Though i'm really not sure why you would want to use this idiom in
sql. I think the
need for SETGT/READP arose from the inability to dynamically sort records
It's the fastest way to get the last record in a set without having to have
indexes in both directions.
As an Amazon Associate we earn from qualifying purchases.
Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.