My Table collation is "utf8_general_ci". If i run a query like:
SELECT * FROM mytable WHERE myfield = "FÖÖ"
i get results where:
... myfield = "FÖÖ"
... myfield = "FOO"
is this the default for "utf8_general_ci"?
What collation should i use to only get records where myfield = "FÖÖ"?
To check records which are NULL, use IS NULL. However, to exclude any of the records, use the NOT IN clause. Use both of them in the same query.
SELECT is used to retrieve rows selected from one or more tables, and can include UNION operations and subqueries.
The MySQL WHERE Clause The WHERE clause is used to filter records. It is used to extract only those records that fulfill a specified condition.
SELECT * FROM table WHERE some_field LIKE ('%ö%' COLLATE utf8_bin)
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With