fixing the error in io/sql.py
Not able to find an testing module in for io/sql.py. And I don't have time to create one now. So I paste the testing code below, which can be added into pandas later on.

```
#!/usr/bin/env python

from pymysql import connect
from pandas.io.sql import read_frame

con = connect(host='genome-mysql.cse.ucsc.edu', user='genome', db='mm9')
sql = 'select geneName as symbol, name as refSeq, chrom, strand, txStart, txEnd from refFlat limit 5'
df = read_frame(sql, con)
print df
```

Hi pengyu, you can check out /pandas/io/sql/tests/test_sql.py for the testing module for sql.py. Thanks.
 I see the following test code for testing read_frame. Yet, it can't catch the error that I fixed. I'm not familiar with the testing in pandas. Could anybody improve the testing code so that it can catch this error?

```
 36         result = sql.read_frame("select * from test", con=self.db)
```
 instead of passing in self.db you can use your own con object.
if you search around in the file you'll see that self.db is part of the initial test setup.
 You misunderstood what I mean. I don't understand why line 36 did catch the error.

I tried my testing code on sqlite3, it works the same as pymysql and MySQLdb. So, theoretically speaking, even the testing code in line 36 is for sqlite3, as long as there is converge for the error, it should catch it.

But it seems that it doesn't cover the error. I can not quickly add some code (just based on sqlit3 instead of pymysql) to cover the error, as I'm not familiar with the testing framework.
 Thanks. Changed this to only iterate over the result of `cur.fetchall()` if it's a non-list
