That's probably MySQL rather than Laravel
You'll need to write a raw SQL command like:
$a = Items::whereRaw("BINARY code = '$code' ");
When I write my pure PHP code and perform queries i had never before met this problem. Maybe by luck. But how can i solve without putting this on every query? Can i change any MAIN LARAVEL FILE so that this happens ALWAYS by default???
I found a solution. In the config file, wher the mysql configuration I put utf8_bin instead of unicode_ci and reset migrations.
Now it performs the queries correctly
Sign in to participate in this thread!
The Laravel portal for problem solving, knowledge sharing and community building.
The community