?
Solved

Count how many leads each user has

Posted on 2010-08-31
4
Medium Priority
?
296 Views
Last Modified: 2012-05-10
Hi,
I have two tables

tblUsers
UserID  UserName

tblLeads
LeadID  UserID  LeadName

and I need to display how many Leads each User has.  The data is being displayed in a Users table with repeat region.   I should probably make a separate RecordSet for this calculation.
0
Comment
Question by:napsternova
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
4 Comments
 
LVL 58

Accepted Solution

by:
cyberkiwi earned 1000 total points
ID: 33571247
select u.userId, u.username, count(l.leadid) as numofleads
from tbluser left u join tblleads l on u.userid=l.userid
group by u.userId, u.username
0
 

Author Comment

by:napsternova
ID: 33571583
Yep I believe that is it.
0
 

Author Comment

by:napsternova
ID: 33572638
Strange, the repeat region only displays the count of the first record.  User 1 has 3 so it repeats 3
0
 

Author Closing Comment

by:napsternova
ID: 33572903
Got it, thanks
0

Featured Post

What does it mean to be "Always On"?

Is your cloud always on? With an Always On cloud you won't have to worry about downtime for maintenance or software application code updates, ensuring that your bottom line isn't affected.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Keep your audience engaged and get the most out of your next presentation with these quick Prezi tips.
Originally, this post was published on Monitis Blog, you can check it here . In business circles, we sometimes hear that today is the “age of the customer.” And so it is. Thanks to the enormous advances over the past few years in consumer techno…
The viewer will learn how to create and use a small PHP class to apply a watermark to an image. This video shows the viewer the setup for the PHP watermark as well as important coding language. Continue to Part 2 to learn the core code used in creat…
Not only does Prezi allow you to create non-linear presentations, it also makes it easy to apply transition animations between your frames. Learn how to apply a fade-in transition to select items and entire frames in this tutorial Select "Edit Path"…
Suggested Courses

765 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question