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 use of value function?
What does reorg do in db2?
Can you tell me how can you find out the # of rows updated after an update statement?
What are types of indexes?
How to execute stored procedure in db2 command editor?
What is the difference between oracle and db2?
What is package in cobol db2?
In case if at some point of time db2 is down, would that impact the pre-compilation process of a db2-cobol program?
run jcl for cobol+db2 pgm?.. //jobcard //step001 exec pgm=ikjeft01 //systin dd * DSNSYSTEM(--------) RUN PROGRAM(MYPGMNAME) PLAN(-----), LIB(-------), PARMS(------) /* WHAT WILL U GIVE INSIDE THE BRACKETS... WHAT IS PLAN,PACKAGE,BIND?..PLAN N PACAKGES ARE GENERATED BY ?...
What is db2 optimizer?
Is db2 a mainframe?
What is innodb buffer pool?
What is db2 purescale?
Why do we bind in db2?
What is the reason behind not using select * in embedded sql programs?