How do you group and count ID's with decimals

  • Thread starter Thread starter Gabe Portillo via AccessMonster.com
  • Start date Start date
G

Gabe Portillo via AccessMonster.com

I have a DBA, where I want to group and query all records by the ID's, and
count the frequency of the record by its whole number. For example my DBA
looks like this:

ID Name Issue Email etc...
1.1
1.2
1.3
2.1
2.2

I want to see how many #1's I have and so on. Can someone please advise if
this is possible? If you need more info let me know. Thx, GP
 
I see 5 #1's. Would this be a correct number? If not, you might want to be
more specific.
 
Sorry, looking for the whole number count (1, 2, 3, etc..) not with the
decimal, such as:

1.1
1.2
1.3

The above example I would like to be counted as 3 record entries for the ID
#1. How do I do this?
 
SELECT Left([YourField], Instr([YourField],".")) as Num, Count(*) as NumOf
FROM tblYourTable
GROUP BY Left([YourField], Instr([YourField],".")) ;
 
Back
Top