Nolanc
asked on
More Than One Counter In SQL Statementt
Hi
Please Consider the following SQL Statement:
sSQL = "Select SalLevel, Count(Gender = 'Male') As MaleCnt, Count(Gender = 'Female') As FemCnt From Employees Group By SalLevel"
When I execute the above statement, I get the Grouping correct except that my FemCnt is Equal to my MaleCnt. And my MaleCnt is correct.
Can somebody please detect what I am doing wrong.
I am using VB.Net 2010 and running under Windows 7.
Many thanks
Please Consider the following SQL Statement:
sSQL = "Select SalLevel, Count(Gender = 'Male') As MaleCnt, Count(Gender = 'Female') As FemCnt From Employees Group By SalLevel"
When I execute the above statement, I get the Grouping correct except that my FemCnt is Equal to my MaleCnt. And my MaleCnt is correct.
Can somebody please detect what I am doing wrong.
I am using VB.Net 2010 and running under Windows 7.
Many thanks
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
Brilliant solution. Thank you.