Help with Iteration

Aaron Brady castironpi at gmail.com
Sat Oct 18 15:46:14 EDT 2008


Chris McComas wrote:
> actually i'm running it online, with a mysql db. so in the db there is
> a table CollegeYear with the following fields:
>
> name
> rating
> change
> wp
>
> then another table Games
>
> date
> year
> team_1
> team_1_score
> team_2
> team_2_score
>
> it goes through and calculates everything, then when it's time to
> compute the rating i have say this code:
>
> http://dpaste.com/85300/
>
> it goes through and computes them, then add the new rating and
> absolute value of the changed rating to the db. what i need now is a
> way to get the largest entry for 'change' and if it is greater than
> 0.00005 then do this code again. if it is less than 0.00005 then we're
> done.

What about "SELECT MAX( rating ) FROM CollegeYear"?




More information about the Python-list mailing list