crystal-lang / crystal-mysql

MySQL connector for Crystal
MIT License
107 stars 36 forks source link

Add support for bit(1) reading #68

Open girng opened 5 years ago

girng commented 5 years ago

Was reading over #12 but am not sure if it's related :P

I have a bit(1) field in MYSQL called hardcore:

The query_all: db.query_all "select hardcore from rpg_characters where user_id = ? ", client.user_id, as: {Bool}

The error: not supported read

I've tried UInt8, Int8, and BitArray.new(1) with no prevail. I'm not sure if this is a suggestion (if it can be done already, then please close). But figured I'd make an issue to shed some light on it. Thanks for reading