MySQL Forums
Forum List  »  Newbie

How to count the number of elements for each ID?
Posted by: Eesa Sandani
Date: April 10, 2014 12:39PM

I am trying to count the number of times a customer has been contacted with and I wanna lets say show the counts for each customer. i am trying the following but it only gives me 1 as the count.
select indiv_id, count(last_contact_date) as counts from campaign.indiv
where last_contact_date>= 28000
group by indiv_id

Options: ReplyQuote


Subject
Written By
Posted
How to count the number of elements for each ID?
April 10, 2014 12:39PM


Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.