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                      
tip   SiteMap shows list of All Categories in this site.
Google
 
Categories  >>  Software  >>  Databases  >>  SQL PLSQL
 
 


 

 
 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
what is the output of this query selet * from employee 
where 1=2  ??
 Question Submitted By :: Mreddy
I also faced this Question!!     Rank Answer Posted By  
 
  Re: what is the output of this query selet * from employee where 1=2 ??
Answer
# 1
2
 
Is This Answer Correct ?    2 Yes 16 No
Anjali.psn_08@yahoo.com
[CTS]
 
  Re: what is the output of this query selet * from employee where 1=2 ??
Answer
# 2
It will return 0 rows as 1 will never be ewual to 2
 
Is This Answer Correct ?    24 Yes 1 No
Priyanka Agarwal
 
 
 
  Re: what is the output of this query selet * from employee where 1=2 ??
Answer
# 3
no rows selected
 
Is This Answer Correct ?    16 Yes 0 No
Narendradivvela
 
  Re: what is the output of this query selet * from employee where 1=2 ??
Answer
# 4
It will return 0 rows....since condition in where clause 
will fail as 1 is not equal to 2
 
Is This Answer Correct ?    3 Yes 0 No
Rohan Mhatre
 
  Re: what is the output of this query selet * from employee where 1=2 ??
Answer
# 5
indeed it will return o rows, but the goal behind is to 
create a new table t2 as select * from t1 where 1=2, where 
just the structure of table t1 will be copied without 
copying data from table t1.
 
Is This Answer Correct ?    3 Yes 0 No
Julien
 
  Re: what is the output of this query selet * from employee where 1=2 ??
Answer
# 6
In Oracle 10g :
---------------

no rows selected.


E.g:
----

SQL> SELECT * FROM job;

    EMPNO JOBTITLE
--------- --------------------
        1 Tester
        2 Accountant
        3 Developer
        4 COder
        5 Director
        6 Mediator
        7 Proffessor
        8 Programmer
        9 Developer

9 rows selected.

SQL> SELECT * FROM job WHERE 1=2;

no rows selected.
 
Is This Answer Correct ?    0 Yes 0 No
Selvaraj V, Anna University
 

 
 
 
Other SQL PLSQL Interview Questions
 
  Question Asked @ Answers
 
What is ROWID?  6
How can we overcome recursive triggers in SQL? iFlex1
SELECT emp_num, years, SUM(salary) FROM sales UNION ALL SELECT emp_id, SUM(takehomepay) FROM marketing What error is present in the sample code above? 1. Queries being combined with the UNION ALL statement are not allowed to have SELECT lists with a different number of expressions. 2. You are not allowed to use aggregate functions within two queries joined by a UNION ALL statement. 3. The UNION ALL statement incorrectly combines the "years" result from the first query with the "SUM (takehomepay)" result from the second query. 4. Unless the UNION ALL statement is replaced with a UNION statement, the queries will return duplicates. 5. The "emp_id" column from the second query must be renamed (or aliased) as "emp_num" so that it corresponds to the column name from the first query. Otherwise, the queries will not execute.  3
What is an Integrity Constraint?  4
how instead of triger is helpful for mutating tables errors handlling ? Oracle2
State the difference between implict and explict cursor's?  6
What are the new features in Oracle 10g. Compared to Oracle 9i? Polaris1
Which one of the following join types will always create a Cartesian Product? 1. CROSS JOIN 2. LEFT OUTER JOIN 3. RIGHT OUTER JOIN 4. FULL OUTER JOIN 5. INNER JOIN  2
Can we use SQL%ISOPEN in implicit cursors? Does this attribute works properly in Implicit Curosors?  2
how to get the third quarter of employee details from emp? CompuTech1
Where the integrity constrints are stored in Data Dictionary?  1
What are the return values of functions SQLCODE and SQLERRM ? PreVator2
What are the modes of parameters that can be passed to a procedure ?  2
Wat is SGA ? ABB1
What is RAC in oracle?  3
write a query to delete similar records in different tables with same structure  4
What is difference between triggers and stored procedures. And advantages of SP over triggers ? TCS2
Explain UNION,MINUS,UNION ALL, INTERSECT?  1
how can we find the select statement is indexed or not? CTS2
write a query to display diference between two dates in sql server  2
 
For more SQL PLSQL 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