i have a table student like
sname
-----
ram
ram
ram
raj
raj
raj
i need the output like
sname
-----
ram
raj
ram
raj
ram
raj

Answer Posted / mala

select a.tnam,b.tnam from (select tnam from temp where tnam
= 'Ram' ) a,
(select tnam from temp where tnam = 'Raj' ) b

Is This Answer Correct ?    1 Yes 2 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What are the risks of storing a hibernate-managed object in a cache? How do you overcome the problems?

772


Why do we backup Active Directory ?

795


What is query parameter in ssrs?

132


What are xml indexes?

697


What is a hint?

738






What is transaction server implicit?

689


Is sql different from sql server?

689


What command is used to create a database in the sql server and how?

830


What are points to remember while using the fillfactor argument?

714


What are different types of statements that are supported by sql?

775


What is the function of inner join?

752


What are joins in sql and what are the different types of joins?

712


Explain transaction server isolation?

740


How to change a login name in ms sql server?

708


What is the use of sql profiler in sql server 2012?

663