Yea, I modified it so a flat text file is generated from the mysql database and that's what the php script uses to get the right picture vs doing a lookup for each picture request. This way I can still manage the site, keywords, comments, etc but won't overtax mysql. Either I'll continue to do it that way or I'll just figure out what the proper way of tuning mysql is so it runs a bit better. It might just need some cache tuning.
Carl