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...


how to copy only distinct data into another table which is not already exist in database?

Answers were Sorted based on User's Feedback



how to copy only distinct data into another table which is not already exist in database?..

Answer / karthik soundararajan

TableA -- Existing Table

ID
5
5
5
5
5

Solution : SELECT DISTINCT ID INTO TableB FROM TableA

It create a table called TableB and insert only one record as shown below:

ID
5

Is This Answer Correct ?    3 Yes 1 No

how to copy only distinct data into another table which is not already exist in database?..

Answer / sheshu4040

SELECT DISTINCT * INTO TABLE_NEW FROM TABLE_EXISTING

Is This Answer Correct ?    1 Yes 0 No

Post New Answer

More SQL Server Interview Questions

What is 3nf normalization form?

0 Answers  


What is normalization? Explain its different types?

0 Answers   GE, Maveric,


What is difference between process and thread? Explain lazy writer funcationality.

2 Answers   Microsoft,


What is bit data type? What's the information that can be stored inside a bit column?

0 Answers  


What happens when unicode strings concatenate with non-unicode strings?

0 Answers  


What is raiseerror? What is raiseerror?

0 Answers  


How do I install only the client tools of sql server 2000?

0 Answers  


What are the difficulties faced in cube development? : sql server analysis services, ssas

0 Answers  


How to call a function from a stored procedure in SQL Server ?

0 Answers   HCL,


1.What is the deferece between DBMS & RDBMS? 2.How can you trouble shoot? If u will get error while installing sql server? 3.How can u trouble shoot slow running query? 4.how can u trouble log shipping errors? 5.why do we use merge replication instead of T.log replication?

7 Answers   Microsoft,


What is the difference between a unique key and primary key?

0 Answers  


What is postgresql server?

0 Answers  


Categories