![]() |
help with query to select counts
I want to select the number of records for each idnumber that exists. In the below example, there are three 2's, four 3's, and three 4's. I want to capture this information in a single query if possible.
I know how to capture a record count for a single idnumber, but I'm not sure how to do capture counts for multiple idnumbers in one query. An example of the table: Code:
____________________ |
you need grouping:
[SQL]SELECT COUNT(*), idnumber FROM table GROUP BY idnumber[/sql] |
i think he wants to capture the count of 2, then the count of 3's then the count of 4's
if that's the case, i'm not sure how to do it i'm afraid, it's what i'm reading up on now, but i'm pretty certain it's via a "while" |
Quote:
|
Quote:
|
You're welcome Jake :)
|
All times are GMT. The time now is 04:17 PM. |
Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
![]() |
|
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|