Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

wirte a query to remove null? following table are

col1 col2 col3
dinesh null null
null suresh null
null null prakesh
i want the output like

col1 col2 col3
dinesh suresh prkaesh

Answer Posted / ajitnayak

select distinct col1 from samp
where col1 is not null
union all
select distinct col2 from samp
where col2 is not null

Is This Answer Correct ?    0 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What do you mean by rowid?

917


What is dense_rank?

879


What is clause?

1067


what is foreign key? : Sql dba

971


How many types of triggers exist in pl/sql?

1011


How does sql profiler work?

966


How do you get column names only for a table (sql server)?

1101


What are the set operators in sql?

1032


Does sql*plus have a pl/sql engine?

997


Differentiate between sga and pga.

1090


Explain cursor types?

957


what is sub-query? : Transact sql

1041


what are the differences between char and varchar? : Sql dba

1004


Define sql delete statement.

955


Explain what is an index?

1001