1 SELECT a.field1, b.field2, c.field3, d.field4
2 FROM atable a, atable b, ctable c, dtable d
3 ?
4 ORDER BY 1

What is the minimum number of joins that must be specified
on line 3 in the sample code above to properly link the
tables? Notice that the table "atable" is aliased twice:
once as "a" and once as "b."

1. One join
2. Two joins
3. Three joins
4. Four joins
5. Five joins




Answers were Sorted based on User's Feedback



Answer / rao

generally if n tables will n-1 joins
here 4 tables 3joins

Is This Answer Correct ?    8 Yes 1 No

Answer / sss

We need minimum of n-1 joins to join n tables.
here 3 tables are there.
so we need minimum of 2 joins to join the 3 tables

Is This Answer Correct ?    3 Yes 1 No

Answer / arata kumar pattanaik

1 SELECT a.field1, b.field2, c.field3, d.field4 2 FROM
atable a, atable b, ctable c, dtable d 3 ? 4 ORDER BY 1
What is the minimum number of joins that must be specified
on line 3 in the sample code above to properly link the
tables? Notice that the table "atable" is aliased twice:
once as "a" and once as "b." 1. One join 2. Two joins 3.
Three joins 4. Four joins 5. Five joins
Answer
generally if n tables will n-1 joins
here 4 tables 3joins

Is This Answer Correct ?    2 Yes 0 No




Answer / mohan

There should be Three joins in where clause. no point of that the table "atable" is aliased twice. It will treat as two separate tables....

Is This Answer Correct ?    2 Yes 0 No

Answer / rao

generally if n tables will n-1 joins
here 4 tables 3joins

Is This Answer Correct ?    3 Yes 2 No

Answer / satya

HERE WE HAVE TOTAL NO. OF TABLE IS 3 SO NO. OF JOIN REQUIRE
IS 2







Thanks
satya
+919916174212

Is This Answer Correct ?    2 Yes 2 No

Post New Answer



More SQL PLSQL Interview Questions

what is the purpose of update command in oracle?

7 Answers   MBT,


How to call DDL statements from pl/sql?

4 Answers  


take one table is t1 and in that column name is f1 f1 column values are 200 5000 3000 7000 300 600 100 400 800 400 i want display the values asc and desc in a single output. sample output is f1.a 100 200 300 400 500 600 etc...... and f1.d is 5000 4000 3000 2000 1000 etc...

9 Answers   Zensar,


What is a stored procedure ?

5 Answers  


I need a exceptoin in pl/sql block so that if any errors occur in the block then no exception should errors should raise?

1 Answers  






25.67,-1 Trunc = 20 Round= 30 HOW????

2 Answers   Karrox,


Can we use more than one null value for unique key?

31 Answers   Wipro, A1 Technology,


How write primary and foreign key relationship between two tables without using constraints? u can use any of procedure/function/trigger and any sql?

1 Answers   Parexel,


what is the different between unique+not null & primary key,

4 Answers  


Types of cursors and explanation each of them ?

4 Answers   DELL,


In table three columns with 1 milion records(here there is no sequence values) i want add one more column with sequence values from the first how it is posible?

4 Answers   Tech Soft,


I m giving Source, Destination and Age. Write a procedure or function, it will give to u this source to destination tickets are available or not, if available then check this person is senior citizen or not,if this person is senior citizen then give some discount. PLZ give this answer...... Thanks advance.....

2 Answers  






Categories