General information
Category:
Databases,Tables, Views, Indexing and SQL syntax
Title:
SQL , counting a range.
I have 2 fields where I want to do a count using a sql statement. First I have a sex field which contains "m" or "f", and I have a salary field which is numeric. I want to count using ranges, such as, (0.00-9999.99) as r1,(10000.00-19999.99) as r2, (20000.00-29999.99) as r3, etc., and the sex. I would like a report that might look something like this:
range----sex----count()
r1---------f-------5
r2---------f-------5
r2---------f-------5
r3---------f-------4
r3---------f-------4
r1---------m-------5
r2---------m-------5
r3---------m-------4
TIA,
Jim
Next
Reply
View the map of this thread
View the map of this thread starting from this message only
View all messages of this thread
View all messages of this thread starting from this message only