Hello I like to know how to group in access?
I got
1A 4
1B 5
1C 6
2A 7
2B 8
2C 9
I want
N 15
S 24
Hello I like to know how to group in access?
I got
1A 4
1B 5
1C 6
2A 7
2B 8
2C 9
I want
N 15
S 24
Looks like you want to add the number of ___s by the first number in the first column.
Try this in your query:
select iif(left([col1],1)="1","N","S"), sum([col2])
from [tablename]
group by left([col1],1)
substituting my blue variables with your actual table and column names.
Hope this helps! If you need an explanation of the iif() function, and cannot find one online or in the help, PM me.
thanks
Yes I want to add 1A,1B,1C, into one group and 2A, 2B,2C INTO Another group. I'm going to try your method to see if it works.