if suppose i am having an ACCOUNT table with 3 coloumns ACC.
NO,ACC. NAME,ACC. AMOUNT . If a unique index is also
defined on ACC.NO and ACC.NAME then write a query to
retrieve account holders records who have more than 1 ACC.
Answer Posted / suleman
Try this one
select ACC.NO,ACC.NAME
FROM ACCOUNT
group by ACC.NO
HAVING COUNT(*) > 1
| Is This Answer Correct ? | 1 Yes | 1 No |
Post New Answer View All Answers
What is bind plan?
File not opened because library is *PROD and debug is UPDPROD(*NO). ? what may be the reason? how to solve it..?
What is meant by explain?
What is the use of runstats in db2?
What is the difference between plan and package in db2?
Explain the function of data manager.
What is phantom read in db2?
What do you mean by commit and rollback?
Explain correlated sub-queries.
How to find primary key of a table in db2?
How many databases are there?
What is the use of db2 optimizer?
What is db2 bind?
What is with ur in db2?
have 3 tables table1, table2 and table3 which contains employee information. table1 is master table, table2 contains emp details like emp no and so on, table 3 contains emp salary. so if any emp leave company between 25th - 30th of every month it has to get updated in tables. but it is not getting updated. What is the reason.