
Untitled
By: a guest on
Jul 20th, 2012 | syntax:
None | size: 0.46 KB | hits: 8 | expires: Never
Counting rows in mysql database
Name / Point
--------------------
Pikachu / 7
Voltorb / 1
Abra / 4
Sunflora / 3
Squirtle / 8
Snorlax / 12
SELECT count(*) FROM table WHERE Point < 7 ORDER BY Point ASC
SELECT count(*) FROM table WHERE Point < 7 GROUP BY Point
select count(*) from mytable where Point<=7;
select count(*) from table where Point >= least_value and Point<= max_value
SELECT COUNT(*)
FROM table
WHERE POINT <= 7
ORDER BY POINT DESC