I have two tables A and B. Both tables are connected with SSN
number as foreign key. I want to retrieve a column data from B
table. How will you write a query?

Answers were Sorted based on User's Feedback



I have two tables A and B. Both tables are connected with SSN number as foreign key. I want to ret..

Answer / harsha

One can use Inner Join to get data from two tables.

Is This Answer Correct ?    4 Yes 1 No

I have two tables A and B. Both tables are connected with SSN number as foreign key. I want to ret..

Answer / siri

1)select ssn from b;
2)select b1.ssn from a a1,b b1 where a1.ssn=b1.ssn
3)seelct b1.ssn from a a inner join b b1 on a1.ssn=b1.ssn

Is This Answer Correct ?    0 Yes 1 No

I have two tables A and B. Both tables are connected with SSN number as foreign key. I want to ret..

Answer / naidu sekhar yandrapu

SELECT SSN FROM B;

Is This Answer Correct ?    1 Yes 4 No

Post New Answer

More DB2 Interview Questions

What is the usage of open cursor command?

0 Answers  


what is parm utility

2 Answers   IBM,


What is load utility in db2?

0 Answers  


List out the data types available.

0 Answers  


What are the three lock types?

2 Answers  


What is the purpose of the SDSNLOAD dataset in the STEPLIB while running DB2 programs?

2 Answers  


What is meant by explain?

0 Answers  


What is difference between isnull and coalesce?

0 Answers  


Give the COBOL definition of a VARCHAR field.

2 Answers  


What are the three types of page locks that can be held?

1 Answers  


While creating a table, by mistake you have given size of one field as 10. But as per requirement size should be 8. What is your next step?

4 Answers   CTS, IBM,


What is the difference between drop table and delete table?

0 Answers  


Categories