Sort and Count

I have an excel file attached that I need to sort and count.

Column A = M for Male and F for female

Column B = Org Code

I need it sorted by Org Code with a total count of M & F and by Org Code with a count of males only and by Org Code with a count of males only.

I also have this in an Access 2007 DB Table if it makes it easier to do than excel.

Thanks.
CODE-COUNT-2.xlsx
CMILLERAsked:
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

Harry LeeCommented:
Your best and most effect choice would be to use PivotTable.
0
Martin LissOlder than dirtCommented:
When you say "I need it sorted by Org Code with a total count of M & F" do you mean that you want a count of males and females in each org?
0
jerryb30Commented:
I assumed as much. In Access, with table Code_Count,

SELECT Code_Count.[Org Code], Count([Org Code]) AS TotalCode, Sum([Sex]="M")*-1 AS Males, Sum([Sex]="F")*-1 AS Females
FROM Code_Count
GROUP BY Code_Count.[Org Code];
0
Let's GoCommented:
I think HarryHYLee is right.

Does the attached file do what you want?
Copy-of-CODE-COUNT-2.xlsx
0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
CMILLERAuthor Commented:
pfsnet & jerryb30,

Gentleman, thats perfect. Thanks for both options!!
0
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Microsoft Excel

From novice to tech pro — start learning today.