what is the out put of below queries?
a. select * from Emp where null = null;
b. select * from Emp where 1=1;

Answer Posted / radhakrishnan

a) first statement return only table structure (with out
data)
Eg: empid empname

b) second statement return the structure with data.

Eg: empid empname
101 radha
102 krishnan

Is This Answer Correct ?    3 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Explain cursor as data base object?

583


Why it is recommended to avoid referencing a floating point column in the where clause?

542


Explain try...catch with sql server?

602


Explain what stored procedure sp_replcounters is used for? : sql server replication

1010


How does stuff differ from the replace function?

556






How to display a past time in days, hours and minutes?

577


What are the advantages of log shipping?

567


How do I find the sql server database version?

534


can any body tell me how to know the password of current user in sql server

1581


How to drop an existing table?

557


How to get a list of columns in a view using the "sp_columns" stored procedure?

621


What are the limitations/drawbacks or ssrs 2008 r2?

86


What is the difference between coalesce() & isnull()?

535


Explain trigger classes i.e. Instead of and after trigger?

493


How do I know if localdb is running?

521