I'm calling the Facebook graph api via the php sdk and when I call and traverse the array through several nested foreach loops it takes far longer than it should even when I limit the # of records being called. Here's my code:

please use mysqli with prepared statements (php.net/manual/en/mysqli.prepare.php), because even when data comes from a trusted source, its better to escape it anyway and keep yourself safe from SQL injection
–
Ben HughesMay 5 '11 at 22:10

Thanks, I will add that. Any idea as to why this script takes more than 1 minute to run? I'm not calling or writing that much data.
–
mhawkMay 5 '11 at 22:22