Answer Posted / vaneeshh khurana
See there is no direct method to do so, but still if we want
last 5 rows only we can create a logic which is as follows.
1. Declare an array to save the fetch rows with occurs of 5.
2. Now fetch the rows and start saving in that array such
that when the count becomes 5 overwrite the 6th fetch in the
first occurs similarly the 7th fetch on the 2nd occur.
3. Now when all the fetching is done the array will contains
the last 5 fetched rows.
| Is This Answer Correct ? | 2 Yes | 2 No |
Post New Answer View All Answers
Can we update view in db2?
What is a Foreign Key?
How would the varchar column remarks defined?
What are iseries servers?
What is a page in db2?
How to find the maximum value in a column in the db2 database?
How do you pull up a query which was previously saved in qmf?
what is db2 restart?
What does db2 mean?
Can you use max on a char column?
My sql statement select avg(salary) from emp yields inaccurate results. Why?
How to take backup of table in db2?
If the cursor is kept open followed the issuing of commit, what is the procedure to leave the cursor that way?
What is a collection in db2?
How and when does the db2 enforces the unique key?