Hi there!
I need help creating an javascript function that returns the highest average from a table with two columns, datum (stores dates in format 2011-05-04) , mar (stores integers with values 1-10).
The function needs to be able to return the the name of the weekday with the highest average.
The program should later on be able to announce "Your best days are mondays"
The db-loop as it looks today.
function getstatistics(see) {
var db3 = [login to view URL]('[login to view URL]','mar');
var strsql = 'SELECT datum, mar FROM mar order by Datum Asc';
var mittRS2 = [login to view URL](strsql);
while ([login to view URL]()) {
count=count +1;
//insert solution here
[login to view URL]();
}
[login to view URL]();
Should be simple for anyone familiar with javascript.
Need it fast.