This result object does not return rows (dataset version 1.4.5)
ehsen opened this issue · comments
Ehsen Siraj commented
dataset generates error if you try to update a column with rawsql without returning any rows. The column actually updates but generates an exception.
This result object does not return rows. It has been closed automatically.
I think the above error relates to sqlchemy rather then dataset. You can reproduce the error on Windows 7 with a following simple function.
def fix_null_checkout(date, employee_code, check_out_time,check_in_time):
statement = f"UPDATE Attendance SET check_out='{check_out_time}',check_in='{check_in_time}' WHERE date='{date}' AND employee_code='{employee_code}'"
try:
attendance_db.query(statement)
return True
except Exception as e:
print(e)
return False
Friedrich Lindenberg commented
I think this was fixed in 1.5.0, see c13b79f can you check?