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

I am having a table with columns
ID NAME
1 x and the requirement is to get the o/p like this
1 y ID Count(*)
1 z 1 3
2 a 2 2
2 b
3 c
so write a sql query to get the id n how many times its
count of repetition n there u shouldn't get the distinct(i.e
id-3)

Reply as early as possible

Answer Posted / sambu

select id,count(*) from <table name>
group by id having count(*)>1;

The above gives us desired output

Is This Answer Correct ?    8 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Why can't we connect source qualifier and aggrigator transformation to an expression ? Why they resticted to conncet 2 active trasformations to an passive transformation ?

2121


What is the use of code page?

1010


How do you load only null records into target?

1141


How to improve the performance of a session using sorter transformation?

1092


write a query to retrieve the latest records from the table sorted by version(scd)

1004


What is a mapplet/worklet in informatica?

1120


What is a transaction control transformation?

1143


How to implement security measures using repository manager?

1082


What is the procedure for creating independent data marts from informatica 7.1?

1000


What is data transformation manager process?

1078


What are Dimensional table?

999


What are the types of data warehouses?

1425


How you can differentiate between connected lookup and unconnected lookup?

1006


Enlist the tasks for which source qualifier transformation is used.

980


What are batches?

1010