[quote]Does anybody know why this is not working:
“SELECT DISTINCT(rowerid), age, weight, city, state, country, date_rowed, distance, time, comments FROM workouts WHERE distance=‘500’ ORDER BY time ASC”
It keeps selecting all the values, even if they are the same rowerid[/quote]
DISTINCT is an option, not a function like COUNT().
“The ALL, DISTINCT, and DISTINCTROW options specify whether duplicate rows should be returned. If none of these options are given, the default is ALL (all matching rows are returned). DISTINCT and DISTINCTROW are synonyms and specify removal of duplicate rows from the result set.”
See http://www.w3schools.com/SQl/sql_distinct.asp for an example of its use.