Select empno, sal from emptbl where empno < 101.By this
query can we fetch first 100 recs? where empno is primary
key.It won't throw -811 error? if it wont,then what is use
of cursor technique while fetching first 100 recs.
Please need more clarification.
Answer Posted / kingmanish
Yes this query will fetch multiple records.
If tried to fetch these records in variables in a sql query
it will give -811 error.
In order to be able to handle these multiple records we
have to use cursor.
Now using cursor we can process each of these records one
at a time and thus cursors come handu here.
| Is This Answer Correct ? | 6 Yes | 0 No |
Post New Answer View All Answers
What is explain plan in db2?
How can the firstname and the lastname from the emp table be concatenated to generate complete names?
How to connect to db2 database from windows command line?
How do you eliminate duplicate values in db2?
What is dbrm in db2 database?
How and when does the db2 enforces the unique key?
Define db2 and its databases?
How do I delete a column in db2?
What is temporal table in db2?
What is the difference between cursor stability and repeatable read isolation levels?
What type of database is db2?
Explain package in db2 and its advantages?
While unloading huge amount of data from table. Suddenly job failed some error. Imagine 1M data unloading, In that 90% data unloaded only 10% left, So if want to unload the rest 10% what needs to be done? Whether do i need to start from top or anything ?
What parameters are used to control the free space in DB2?
What is ibm db2 database?