Fix TypeError: value is of wrong type for this column

Fixes #41