suppose in my table 10 rows are there , i want to update odd
rows salary as 90000 ? how u do it ? any one help me ? what
do we use here cursor-fetch or normal sql ?
Answer Posted / harsha
The first answer is correct. It has a logic to select only
ODD rows(look at the two fetch statements).
Another logic to select only ODD rows.
SELECT SAL FROM EMP WHERE MOD(SAL,2)=1
| Is This Answer Correct ? | 1 Yes | 2 No |
Post New Answer View All Answers
What is catalog database in db2?
What is the syntax for FETCH in DB2 ?
What is the advantage in De-normalizing tables in DB2?
what is db2 restart?
I understand Join always perform better than subqueries. Then what is the advantage/use of Subqueries/correlated subqueries etc.,in DB2 programming.Please explain.
How can the firstname and the lastname from the emp table be concatenated to generate complete names?
Explain packages.
Explain about rct in db2?
Mention the location where the output received from explain statement is stored.
Why cursor is used in db2?
What is dclgen in db2?
What is the difference between db2 and oracle?
What is bind plan?
What is a db2 tablespace?
What is bind package and plan in db2?