INWTlab / dbrequests

python package built for easy use of raw SQL within python and pandas projects
MIT License
5 stars 2 forks source link

Bug: dbrequests.mysql: ValueError for empty result sets #32

Closed wahani closed 4 years ago

wahani commented 4 years ago

Currently we get an error on empty result sets with send_query:

>>> import dbrequests.mysql as mysql
>>> with mysql.Database(url) as db:
...     db.send_query('select * from cats where id < 0', table='cats')
ValueError: The names list has length 4, while the Frame has 0 columns