What are sub-queries? Give example? In which case
sub-queries are not feasible?

Answers were Sorted based on User's Feedback



What are sub-queries? Give example? In which case sub-queries are not feasible?..

Answer / bernatshaw

Sub-query means a Query within a Query.
This is the Example:
Select Employee_Id, Employee_name From Employees Where
Employee_Id IN (Select Mgr_Id from Manager)

Is This Answer Correct ?    12 Yes 2 No

What are sub-queries? Give example? In which case sub-queries are not feasible?..

Answer / rajendra

Sub query mean query within query ,but when you use sub
query on larg amount data that time it is not feasible

Is This Answer Correct ?    4 Yes 3 No

What are sub-queries? Give example? In which case sub-queries are not feasible?..

Answer / akhil

text and image datatypes are not allowed in
subqueries.Subqueries cannot manipulate their results
internally, that is, a subquery cannot include the order by
clause, the compute clause, or the into keyword.
Correlated (repeating) subqueries are not allowed in the
select clause of an updatable cursor defined by declare cursor.

Is This Answer Correct ?    1 Yes 2 No

What are sub-queries? Give example? In which case sub-queries are not feasible?..

Answer / amit kumar

A subquery is simply a SELECT query within a SELECT query.

example:-

SELECT City, Salary, (SELECT AVG(Salary) FROM Employee)
AS AvgSalary FROM Employee;

Is This Answer Correct ?    1 Yes 4 No

Post New Answer

More SQL Server Interview Questions

how many bits ip address consist of? : Sql server database administration

0 Answers  


What is the use of SCOPE_IDENTITY() function?

2 Answers  


OPTIMIZATION OF SP,CURSOR,TRIGGERS

0 Answers  


What happens if we shrink log file in sql server?

0 Answers  


What is recursion? Is it possible for a stored procedure to call itself or recursive stored procedure?

0 Answers  






How to install sql server 2005 express edition?

0 Answers  


What are the essential components of sql server service broker?

0 Answers  


Can we write a distributed query and get some data which is located on other server and oracle database?

0 Answers  


There is table like Events...in that name ,startdate ,enddate,location are the column names write a stored Procedure for this table to get events by Months "GetEventsByMonths"

2 Answers  


Define compound operators?

0 Answers  


can we call stored Procedure in Function in Sql Server 2000 and vice versa.

3 Answers   C3I, eSoft, iPRO Solutions, Wipro,


What is Files and Filegroups in SQL Server & it's implementation.

1 Answers   Zenith,


Categories