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 / mallikarjun
select distinct ACC.NO,
ACC. NAME,
ACC. AMOUNT
from account
where acc.name in
( select distinct acc.name
from account
group by acc.name
where count(acc.no) > 1)
Is This Answer Correct ? | 3 Yes | 1 No |
Post New Answer View All Answers
What is the role of data manager in the db2 database?
Following a db2 update statement, what is the quickest way to compute the total number of updated rows?
What is catalog database in db2?
On which levels locks can be applied?
I HAVE 500 ROW TO UPDATE I WOULD LIKE TO USE ROLLBACK ALONG WITH COMMIT.WHAT IS THE SYNTAX TO CODE COMMIT AND ROLLBACK FOR EVERY 100 ROWS.AND HOW THE CURSOR ROLLBACK TO THE LAST COMMITTING POINT.
Hi Everyone... Under the Logical files, when am working on multiple rec format logical file, I have joined two pf's using the multiple record format logical file concept, but when i run queried the LF only the first mentioned pf records are reflecting and I am not able to see any of the field records specified under the second pf. Kindly let me know whats the reason behind this. Below is the str of LF., R rec PFILE(LOGICAA) CUSTNO CUSTNAME BILL K CUSTNO R rec1 PFILE(LOGICAA1) CUSTNO ADD K CUSTNO .....
Explain what are the various isolation levels possible?
What parameters are used to control the free space in DB2?
What is the meaning concurrency in the db2 database?
What is a cursor in programming?
What is image copy in db2?
what are bind concepts in db2 cobol?
Is db2 a programming language?
Suppose pgm A calling Pgm B .Pgm B has some Db2 program. at the time of compilation should plan and package will be created for both A and B or only B? What is the concept?
Mention the different locking levels that are available in db2.