Revert "cast to char for postgres and mysql compatibility"

This reverts commit 3a7e63a94f93e5caf8b34025880fa2bc9813635c.