ALLInterview.com :: Home Page KalAajKal.com
 Advertise your Business Here     
Browse  |   Placement Papers  |   Company  |   Code Snippets  |   Certifications  |   Visa Questions
Post Question  |   Post Answer  |   My Panel  |   Search  |   Articles  |   Topics  |   ERRORS new
   Refer this Site  Refer This Site to Your Friends  Site Map  Bookmark this Site  Set it as your HomePage  Contact Us     Login  |  Sign Up                      
Do you have a collection of Interview Questions and interested to share with us!!
Please send that collection to along with your userid / name. ThanQ
Google
 
Categories  >>  Software  >>  Databases  >>  SQL Server
 
 


 

 
 Oracle interview questions  Oracle Interview Questions
 SQL Server interview questions  SQL Server Interview Questions
 MS Access interview questions  MS Access Interview Questions
 MySQL interview questions  MySQL Interview Questions
 Postgre interview questions  Postgre Interview Questions
 Sybase interview questions  Sybase Interview Questions
 DB Architecture interview questions  DB Architecture Interview Questions
 DB Administration interview questions  DB Administration Interview Questions
 DB Development interview questions  DB Development Interview Questions
 SQL PLSQL interview questions  SQL PLSQL Interview Questions
 Databases AllOther interview questions  Databases AllOther Interview Questions
Question
Can we rewrite subqueries into simple select statements or
with joins? Example?
 Question Submitted By :: Guest
I also faced this Question!!     Rank Answer Posted By  
 
  Re: Can we rewrite subqueries into simple select statements or with joins? Example?
Answer
# 1
Subqueries can often be re-written to use a standard outer 
join, resulting in faster performance. As we may know, an 
outer join uses the plus sign (+) operator to tell the 
database to return all non-matching rows with NULL values. 
Hence we combine the outer join with a NULL test in the 
WHERE clause to reproduce the result set without using a 
sub-query.
 
Is This Answer Correct ?    3 Yes 0 No
Divya Kalra
 

 
 
 
Other SQL Server Interview Questions
 
  Question Asked @ Answers
 
CREATE TABLE [dbo].[HPMS_CompetencyTypes](CompetencyType varchar(50) ) go create trigger hpms_create_Insert on HPMS_CompetencyTypes for insert as if Exists ( select * from [HPMS_CompetencyTypes] where CompetencyType=(select * from [HPMS_CompetencyTypes])) begin Rollback tran Raiserror ('duplicate value',12,6) go insert HPMS_CompetencyTypes (CompetencyType) values ('new') I'm new to trigger can any one tell me where is the issue. Please.  2
How will oyu test the stored procedure taking two parameters namely first name and last name returning full name?  3
What is transcation?Plz give One example?  2
how to retrive only second row from table in sql server 2000? CTS7
What is an execution plan? When would you use it? How would you view the execution plan?  1
Explain sp_configure commands, set commands?  3
how to connect sybase to sql server 2005?. ABC1
in tabase table having a column in it empname field is there which having 5 duplicate values is there i want deleted all the duplicates i want showing only one name only.  7
How do we get month name in SQL Server 2000, Oracle, MS Access?  9
how to rename the table  3
Display a roll having miminum marks in two subjects? Patni7
how to copy sysdatabase file from c: Drive to D: Drive in SQL Server. IBM4
select top 5 * from emp order by newid() my question is , how this query get executed?  4
Hi Friends, I have a table in which there are thousands of records and in city field there is NULL value for all records now i want to change that null value with distinct values in each record say delhi, bihar, agra, jaipur etc, what will be the query for that????? its not possible to update thousands of records one by one. is there any alternative ...? Plz help ... its urgent Thanx in advance  1
Difference between Function and Stored Procedure? C1-India4
can you any body tell me why are go for the rebuild the master database.what is the reason?  1
What's the difference between DELETE TABLE and TRUNCATE TABLE commands?  9
How to select Distinct columns from the table, table having 20 columns and i want all coulmns Wipro3
WHY CAN WE CREATE ONLY ONE CLUSTERED INDEX ON A TABLE IN SQL SERVER?  6
What should we do to copy the tables, schema and views from one SQL Server to another?  3
 
For more SQL Server Interview Questions Click Here 
 
 
 
 
 
   
Copyright Policy  |  Terms of Service  |  Help  |  Site Map 1  |  Articles  |  Site Map  |   Site Map  |  Contact Us interview questions urls   External Links 
   
Copyright © 2007  ALLInterview.com.  All Rights Reserved.

ALLInterview.com   ::  Forum9.com   ::  KalAajKal.com