matt-42 / lithium

Easy to use C++17 HTTP Server with no compromise on performances. https://matt-42.github.io/lithium
https://matt-42.github.io/lithium
MIT License
1.26k stars 91 forks source link

mysql_bind_output resize #76

Closed gtustus123 closed 2 years ago

gtustus123 commented 3 years ago

Hi, I am using longtext in my sql having several thousands long amino acid sequences. But using lithium orm find_one() the result contains only the first 100 character of them. I dag into your code and founded the length of mysql results string is limited to 100 character, e.g in sql/internal/mysql_bind.hh line 111 It has any reason? May I rewrite v.resize(100) to v.resize(*real_length) ? Thanks.

matt-42 commented 3 years ago

Hi @gtustus123

Thanks for the report, the strings are not limited to 100 characters, this is a bug with prepared statement. I'm fixing this right now.

matt-42 commented 3 years ago

Fixed in 465f9ca816a1ca77798737ae8f454ad1e0c7310a