Monday, August 16, 2004

Molasses in January

I'm no expert on the guts of databases, but as far as I can tell there is no reason on God's green earth that this

insert into soccerstats
select s.id,games.game_id,
s.school_id,s.player_id,s.goals,
s.assists,s.saves,s.timestamp
from soccerstatsold s 
left join games on (
(s.game_id = games.old_id) and 
(games.sport='7' or games.sport='14'))

should be taking over eight minutes to run. It's maddening! Think I need to get a copy of this.

No comments: